简体   繁体   English

Eclipse-发生错误

[英]Eclipse - An Error Has Occured

For some reason I'm no longer able to fire up eclipse as every time I open it, i get an error that states : An error has occures, see log file x.log 由于某种原因,每次打开时我都无法启动日食,但出现一个错误,指出:发生了错误,请参阅日志文件x.log。

  • I looked around online for this issue and one of the things that seamed to have solved it is by deleting all .snap files from .metadata.plugins\\org.eclipse.core.resources folder but I couldn't find any .snap files (PS: this is now a clean install of eclipse) 我在网上环顾了这个问题,解决了这一问题的方法之一是从.metadata.plugins \\ org.eclipse.core.resources文件夹中删除所有.snap文件,但我找不到任何.snap文件( PS:现在是eclipse的全新安装)

  • I also tried re-installating JDK and JRE 我也尝试过重新安装JDK和JRE

java version "1.8.0_11" Java(TM) SE Runtime Environment (build 1.8.0_11-b12) Java HotSpot(TM) 64-Bit Server VM (build 25.11-b03, mixed mode) Java版本“ 1.8.0_11” Java™SE运行时环境(内部版本1.8.0_11-b12)Java HotSpot(TM)64位服务器VM(内部版本25.11-b03,混合模式)

  • I also tried running eclipse with cmd with eclipse - clean command but same error pops up. 我也尝试过使用带有eclipse的cmd运行eclipse-clean命令,但会弹出相同的错误。

I'm very new at this..can you please tell me what I'm doing wrong :) 我对此很陌生..你能告诉我我做错了吗:)

Here's the log file: 这是日志文件:

    !SESSION 2014-09-04 23:03:28.569 -----------------------------------------------
eclipse.buildId=M20060921-0945
java.version=1.7.0_60
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_CA
Command-line arguments:  -os win32 -ws win32 -arch x86

!ENTRY system.bundle 4 0 2014-09-04 23:03:28.777
!MESSAGE FrameworkEvent.ERROR
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.osgi.framework.internal.core.SystemBundleActivator.start() of bundle system.bundle.
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:1010)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:966)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:549)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:484)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:275)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.launch(StartLevelManager.java:245)
    at org.eclipse.osgi.framework.internal.core.SystemBundle.resume(SystemBundle.java:155)
    at org.eclipse.osgi.framework.internal.core.Framework.launch(Framework.java:503)
    at org.eclipse.osgi.framework.internal.core.OSGi.launch(OSGi.java:51)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:289)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:173)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
    at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
    at org.eclipse.core.launcher.Main.run(Main.java:977)
    at org.eclipse.core.launcher.Main.main(Main.java:952)
Caused by: java.lang.IllegalStateException
    at org.eclipse.osgi.internal.baseadaptor.BaseStorage.checkSystemState(BaseStorage.java:654)
    at org.eclipse.osgi.internal.baseadaptor.BaseStorage.getStateManager(BaseStorage.java:634)
    at org.eclipse.osgi.baseadaptor.BaseAdaptor.getPlatformAdmin(BaseAdaptor.java:385)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAdaptorHook.frameworkStart(EclipseAdaptorHook.java:80)
    at org.eclipse.osgi.baseadaptor.BaseAdaptor.frameworkStart(BaseAdaptor.java:260)
    at org.eclipse.osgi.framework.internal.core.SystemBundleActivator.start(SystemBundleActivator.java:55)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:991)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:985)
    ... 18 more
Root exception:
java.lang.IllegalStateException
    at org.eclipse.osgi.internal.baseadaptor.BaseStorage.checkSystemState(BaseStorage.java:654)
    at org.eclipse.osgi.internal.baseadaptor.BaseStorage.getStateManager(BaseStorage.java:634)
    at org.eclipse.osgi.baseadaptor.BaseAdaptor.getPlatformAdmin(BaseAdaptor.java:385)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAdaptorHook.frameworkStart(EclipseAdaptorHook.java:80)
    at org.eclipse.osgi.baseadaptor.BaseAdaptor.frameworkStart(BaseAdaptor.java:260)
    at org.eclipse.osgi.framework.internal.core.SystemBundleActivator.start(SystemBundleActivator.java:55)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:991)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:985)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:966)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:549)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:484)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:275)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.launch(StartLevelManager.java:245)
    at org.eclipse.osgi.framework.internal.core.SystemBundle.resume(SystemBundle.java:155)
    at org.eclipse.osgi.framework.internal.core.Framework.launch(Framework.java:503)
    at org.eclipse.osgi.framework.internal.core.OSGi.launch(OSGi.java:51)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:289)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:173)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
    at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
    at org.eclipse.core.launcher.Main.run(Main.java:977)
    at org.eclipse.core.launcher.Main.main(Main.java:952)

!ENTRY org.eclipse.osgi 4 0 2014-09-04 23:03:28.783
!MESSAGE Startup error
!STACK 1
java.lang.RuntimeException: Exception in org.eclipse.osgi.framework.internal.core.SystemBundleActivator.start() of bundle system.bundle.
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:557)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:484)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:275)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.launch(StartLevelManager.java:245)
    at org.eclipse.osgi.framework.internal.core.SystemBundle.resume(SystemBundle.java:155)
    at org.eclipse.osgi.framework.internal.core.Framework.launch(Framework.java:503)
    at org.eclipse.osgi.framework.internal.core.OSGi.launch(OSGi.java:51)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:289)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:173)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
    at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
    at org.eclipse.core.launcher.Main.run(Main.java:977)
    at org.eclipse.core.launcher.Main.main(Main.java:952)
!SESSION Thu Sep 04 23:03:28 EDT 2014 ------------------------------------------
!ENTRY org.eclipse.core.launcher 4 0 2014-09-04 23:03:28.791
!MESSAGE Exception launching the Eclipse Platform:
!STACK
java.lang.NullPointerException
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:186)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
    at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
    at org.eclipse.core.launcher.Main.run(Main.java:977)
    at org.eclipse.core.launcher.Main.main(Main.java:952)

Try to delete the .metadata file and again restart the eclips with the workspace. 尝试删除.metadata文件,然后再次使用工作区重新启动Eclipse。 Due to some changes the metadata may be holding the older information related to eclipse and workspace. 由于某些更改,元数据可能保存着与日食和工作空间有关的旧信息。

安装JDK 1.9后,出现此错误并将其更改为1.8。

您应该将jdk更改为1.8,就可以了。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM