[Fixed] Re: OpenJDK-7 update gives errors in Eclipse-4.2 preferences
Peter Ansell
ansell.peter at gmail.com
Thu Sep 13 00:06:55 UTC 2012
Okay, fixed my issue using a solution from AskUbuntu :
http://askubuntu.com/questions/186986/eclipse-has-multiple-issues-after-jre-6-openjdk-upgrade
sudo apt-get --reinstall install tzdata-java
Cheers,
Peter
On 13 September 2012 10:02, Peter Ansell <ansell.peter at gmail.com> wrote:
> There was also another error at the top of the log which may be closer
> to the root cause:
>
> The following may have set off the chain, as it causes a class
> initialiser to fail:
>
> Caused by: java.lang.NullPointerException
> at sun.util.calendar.ZoneInfoFile.getZoneIDs(ZoneInfoFile.java:790)
> at sun.util.calendar.ZoneInfo.getAvailableIDs(ZoneInfo.java:576)
> at java.util.TimeZone.getAvailableIDs(TimeZone.java:588)
> at com.ibm.icu.impl.JavaTimeZone.<clinit>(JavaTimeZone.java:37)
> ... 22 more
>
> The following bug may be relevant here as it contains the same
> NullPointerException as above, although my file system permissions
> seem to permit reads by anyone so it doesn't exactly match:
>
> http://bugs.sun.com/view_bug.do?bug_id=6529213
>
>
> File permissions for JAVA_HOME/jre/lib/zi/ZoneInfoMappings:
>
> $ env | grep JAVA_HOME
> JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64
> $ ls -lah /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/zi/ZoneInfoMappings
> lrwxrwxrwx 1 root root 61 Sep 12 02:14
> /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/zi/ZoneInfoMappings ->
> ../../../../java-7-openjdk-common/jre/lib/zi/ZoneInfoMappings
> $ ls -lah /usr/lib/jvm/java-7-openjdk-common/jre/lib/zi/ZoneInfoMappings
> -rw-r--r-- 1 root root 15K Sep 11 20:10
> /usr/lib/jvm/java-7-openjdk-common/jre/lib/zi/ZoneInfoMappings
>
>
> The .metadata/.log file starts with:
>
> !SESSION 2012-09-13 08:59:42.484 -----------------------------------------------
> eclipse.buildId=I20120608-1400
> java.version=1.7.0_07
> java.vendor=Oracle Corporation
> BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_AU
> Framework arguments: -product org.eclipse.epp.package.jee.product
> Command-line arguments: -os linux -ws gtk -arch x86_64 -product
> org.eclipse.epp.package.jee.product
>
> !ENTRY org.eclipse.ui.workbench 4 2 2012-09-13 08:59:55.093
> !MESSAGE Problems occurred when invoking code from plug-in:
> "org.eclipse.ui.workbench".
> !STACK 1
> org.eclipse.core.runtime.CoreException: Plug-in
> "org.eclipse.equinox.p2.ui.sdk.scheduler" was unable to instantiate
> class "org.eclipse.equinox.internal.p2.ui.sdk.scheduler.AutomaticUpdateScheduler".
> at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.throwException(RegistryStrategyOSGI.java:194)
> at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:188)
> at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
> at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
> at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
> at org.eclipse.ui.internal.WorkbenchPlugin$1.run(WorkbenchPlugin.java:273)
> at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:52)
> at org.eclipse.ui.internal.WorkbenchPlugin.createExtension(WorkbenchPlugin.java:269)
> at org.eclipse.ui.internal.EarlyStartupRunnable.getExecutableExtension(EarlyStartupRunnable.java:117)
> at org.eclipse.ui.internal.EarlyStartupRunnable.run(EarlyStartupRunnable.java:66)
> at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
> at org.eclipse.ui.internal.Workbench$52.run(Workbench.java:2357)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
> Caused by: java.lang.ExceptionInInitializerError
> at com.ibm.icu.util.TimeZone.getDefault(TimeZone.java:754)
> at com.ibm.icu.util.Calendar.getInstanceInternal(Calendar.java:1626)
> at com.ibm.icu.util.Calendar.getInstance(Calendar.java:1590)
> at org.eclipse.equinox.internal.p2.ui.sdk.scheduler.AutomaticUpdateScheduler.<clinit>(AutomaticUpdateScheduler.java:50)
> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
> at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
> at java.lang.Class.newInstance0(Class.java:372)
> at java.lang.Class.newInstance(Class.java:325)
> at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:184)
> ... 11 more
> Caused by: java.lang.NullPointerException
> at sun.util.calendar.ZoneInfoFile.getZoneIDs(ZoneInfoFile.java:790)
> at sun.util.calendar.ZoneInfo.getAvailableIDs(ZoneInfo.java:576)
> at java.util.TimeZone.getAvailableIDs(TimeZone.java:588)
> at com.ibm.icu.impl.JavaTimeZone.<clinit>(JavaTimeZone.java:37)
> ... 22 more
>
>
> I compiled the TZTest file as suggested at
> https://jira.atlassian.com/browse/FE-2662?focusedCommentId=205020 and
> it reproduces the exception from the Eclipse logs:
>
> $ cat TZTest.java
> import java.util.TimeZone;
>
> public class TZTest {
> public static void main(String args[]) {
> String[] availableIds = TimeZone.getAvailableIDs();
> System.out.println("Length: "+availableIds.length);
> for (int i = 0; i < availableIds.length; i++) {
> System.out.println("ID #"+i+": "+availableIds[i]);
> }
> }
> }
> $ javac TZTest.java
> $ java TZTest
> Exception in thread "main" java.lang.NullPointerException
> at sun.util.calendar.ZoneInfoFile.getZoneIDs(ZoneInfoFile.java:790)
> at sun.util.calendar.ZoneInfo.getAvailableIDs(ZoneInfo.java:576)
> at java.util.TimeZone.getAvailableIDs(TimeZone.java:588)
> at TZTest.main(TZTest.java:5)
>
>
>
> On 13 September 2012 09:29, Peter Ansell <ansell.peter at gmail.com> wrote:
>> Hi,
>>
>> I installed an update to OpenJDK-7 in the last few hours and now
>> Eclipse is failing to let me see the preferences panel for installed
>> JREs, and in addition, I cannot run code inside Eclipse.
>>
>> I get the following error in ~/workspace/.metadata/.log when I try to
>> go to Window->Preferences->Java->Installed JREs, and there is also an
>> error dialog inside Eclipse at the point of failure that doesn't tell
>> me much.
>>
>> Naively I would say that something relating to
>> com.ibm.icu.text.SimpleDateFormat may have changed in the most recent
>> OpenJDK, as it seems to be the root cause.
>>
>> !ENTRY org.eclipse.equinox.registry 4 1 2012-09-13 09:16:18.508
>> !MESSAGE Unable to create the selected preference page.
>> !STACK 0
>> org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter$TerminatingClassNotFoundException:
>> An error occurred while automatically activating bundle
>> org.eclipse.jdt.debug.ui (339).
>> at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:122)
>> at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:469)
>> at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:216)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:395)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:464)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
>> at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
>> at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)
>> at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)
>> at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
>> at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
>> at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
>> at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
>> at org.eclipse.core.internal.adapter.AdapterFactoryProxy.loadFactory(AdapterFactoryProxy.java:136)
>> at org.eclipse.core.internal.runtime.AdapterManager.getAdapter(AdapterManager.java:321)
>> at org.eclipse.core.internal.runtime.AdapterManager.loadAdapter(AdapterManager.java:356)
>> at org.eclipse.debug.internal.ui.actions.ToggleBreakpointsTargetManager$ToggleBreakpointsTargetAdapterFactory.getToggleBreakpointsTarget(ToggleBreakpointsTargetManager.java:339)
>> at org.eclipse.debug.internal.ui.actions.ToggleBreakpointsTargetManager$ToggleBreakpointsTargetAdapterFactory.createDefaultToggleTarget(ToggleBreakpointsTargetManager.java:378)
>> at org.eclipse.debug.internal.ui.actions.ToggleBreakpointsTargetManager.getToggleBreakpointsTarget(ToggleBreakpointsTargetManager.java:539)
>> at org.eclipse.debug.internal.ui.actions.breakpoints.RetargetBreakpointAction.getAdapter(RetargetBreakpointAction.java:47)
>> at org.eclipse.debug.internal.ui.actions.RetargetAction.partActivated(RetargetAction.java:163)
>> at org.eclipse.debug.internal.ui.actions.RetargetAction.init(RetargetAction.java:96)
>> at org.eclipse.debug.internal.ui.actions.breakpoints.RetargetBreakpointAction.init(RetargetBreakpointAction.java:53)
>> at org.eclipse.ui.internal.WWinPluginAction.initDelegate(WWinPluginAction.java:189)
>> at org.eclipse.ui.internal.PluginAction.createDelegate(PluginAction.java:125)
>> at org.eclipse.ui.internal.WWinPluginAction.refreshActionList(WWinPluginAction.java:165)
>> at org.eclipse.ui.plugin.AbstractUIPlugin$1.run(AbstractUIPlugin.java:485)
>> at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
>> at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)
>> at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3529)
>> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3182)
>> at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1022)
>> at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
>> at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:916)
>> at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:86)
>> at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:585)
>> at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
>> at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:540)
>> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
>> at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
>> at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
>> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
>> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
>> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
>> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>> at java.lang.reflect.Method.invoke(Method.java:601)
>> at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
>> at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
>> at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
>> at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
>> Caused by: org.osgi.framework.BundleException: The activator
>> org.eclipse.jdt.internal.debug.ui.JDIDebugUIPlugin for bundle
>> org.eclipse.jdt.debug.ui is invalid
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:172)
>> at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
>> at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:300)
>> at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
>> at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:263)
>> at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
>> ... 55 more
>> Caused by: java.lang.NoClassDefFoundError:
>> org/eclipse/jdt/debug/core/IJavaHotCodeReplaceListener
>> at java.lang.Class.getDeclaredConstructors0(Native Method)
>> at java.lang.Class.privateGetDeclaredConstructors(Class.java:2404)
>> at java.lang.Class.getConstructor0(Class.java:2714)
>> at java.lang.Class.newInstance0(Class.java:343)
>> at java.lang.Class.newInstance(Class.java:325)
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:167)
>> ... 61 more
>> Caused by: org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter$TerminatingClassNotFoundException:
>> An error occurred while automatically activating bundle
>> org.eclipse.jdt.debug (338).
>> at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:122)
>> at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:469)
>> at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:216)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:395)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:464)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
>> at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
>> at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
>> at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)
>> at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)
>> at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
>> at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
>> at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
>> at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
>> at org.eclipse.debug.internal.core.BreakpointManager.createBreakpoint(BreakpointManager.java:557)
>> at org.eclipse.debug.internal.core.BreakpointManager.loadBreakpoints(BreakpointManager.java:268)
>> at org.eclipse.debug.internal.core.BreakpointManager.initializeBreakpoints(BreakpointManager.java:461)
>> at org.eclipse.debug.internal.core.BreakpointManager.getBreakpoints0(BreakpointManager.java:430)
>> at org.eclipse.debug.internal.core.BreakpointManager.hasBreakpoints(BreakpointManager.java:946)
>> at org.eclipse.debug.internal.ui.actions.breakpoints.RemoveAllBreakpointsAction.isEnabled(RemoveAllBreakpointsAction.java:55)
>> at org.eclipse.debug.internal.ui.actions.AbstractRemoveAllActionDelegate.update(AbstractRemoveAllActionDelegate.java:100)
>> at org.eclipse.debug.internal.ui.actions.AbstractRemoveAllActionDelegate.init(AbstractRemoveAllActionDelegate.java:86)
>> at org.eclipse.debug.internal.ui.actions.breakpoints.RemoveAllBreakpointsAction.init(RemoveAllBreakpointsAction.java:150)
>> ... 30 more
>> Caused by: org.osgi.framework.BundleException: Exception in
>> org.eclipse.jdt.internal.debug.core.JDIDebugPlugin.start() of bundle
>> org.eclipse.jdt.debug.
>> at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:734)
>> at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683)
>> at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
>> at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:300)
>> at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
>> at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:263)
>> at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
>> ... 54 more
>> Caused by: java.lang.NoClassDefFoundError: Could not initialize class
>> com.ibm.icu.text.SimpleDateFormat
>> at org.eclipse.jdt.internal.debug.core.JDIDebugOptions.<clinit>(JDIDebugOptions.java:58)
>> at org.eclipse.jdt.internal.debug.core.JDIDebugPlugin.start(JDIDebugPlugin.java:274)
>> at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711)
>> at java.security.AccessController.doPrivileged(Native Method)
>> at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702)
>> ... 60 more
>>
>>
>> $ java -version
>> java version "1.7.0_07"
>> OpenJDK Runtime Environment (IcedTea7 2.3.2) (7u7-2.3.2-1ubuntu0.12.04.1)
>> OpenJDK 64-Bit Server VM (build 23.2-b09, mixed mode)
>>
>> I have installed Eclipse Juno (version 4.2) myself in /opt/eclipse and
>> the output of /opt/eclipse/eclipse.ini is:
>>
>> $ cat /opt/eclipse/eclipse.ini
>> -startup
>> plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
>> --launcher.library
>> plugins/org.eclipse.equinox.launcher.gtk.linux.x86_64_1.1.200.v20120522-1813
>> -product
>> org.eclipse.epp.package.jee.product
>> --launcher.defaultAction
>> openFile
>> -showsplash
>> org.eclipse.platform
>> --launcher.XXMaxPermSize
>> 2048m
>> --launcher.defaultAction
>> openFile
>> -vmargs
>> -Dosgi.requiredJavaVersion=1.5
>> -Dhelp.lucene.tokenizer=standard
>> -XX:MaxPermSize=2048m
>> -Xms1024m
>> -Xmx4096m
>>
>> The Eclipse About dialog shows the Eclipse Version as:
>>
>> Eclipse Java EE IDE for Web Developers.
>> Version: Juno Release
>> Build id: 20120614-1722
More information about the ubuntu-users
mailing list