Programing

Eclipse는 "Java가 시작되었지만 종료 코드 = 1을 리턴했습니다"오류 메시지를 리턴합니다.

lottogame 2020. 6. 26. 08:09
반응형

Eclipse는 "Java가 시작되었지만 종료 코드 = 1을 리턴했습니다"오류 메시지를 리턴합니다.


이것은 오류 코드의 사진입니다

방금 Windows 용 Android SDK를 다운로드하고 보관 해제했습니다. 나는 현재 W8 64x를 사용하고 있습니다.


오류 메시지는 Java 버전에 문제가 있음을 나타냅니다. JDK가 설치되어 있습니까?

줄 바꿈을 제외하고 다음을 추가하십시오.

/는! 그 \ 것을 확인 -vm옵션이 발생 하기 전에-vmargs 명령 . 이후의 모든 것은 -vmargsJVM으로 직접 전달됩니다.

-vm 
c:/wherever/java/jdk1.6.0_21/jre/bin/server/jvm.dll
-vmargs... 

... eclipse.ini사용하려는 JDK를 가리키고 필요한 Java 버전이 JDK만큼 최신인지 확인하십시오. 이것이 Windows 시스템의 경로입니다. 경로에 대한 자세한 내용은 여기 에서 볼 수 있습니다 (아래로 스크롤).

eclipse.ini파일의 위치를 모르는 경우 : 정기적으로 파일이의 폴더에 있습니다 eclipse.exe.

Edit2 : @KadoLakatt : 최신 Java 버전을 설치 한 이유는 Eclipse가 -vm항목을 찾지 못하면 JVM의 표준 경로를 확인하기 때문입니다 ( 여기 참조 ). 그러나 JVM 사용이 잘못 추측 될 수 있으므로 권장하지 않습니다. Java를 자동으로 업데이트하면 변경 사항이 궁금한 Eclipse 문제가 발생할 수 있습니다. eclipse.ini확실하게 특정 폴더로 설정하는 것이 좋습니다.


이 오류가 파란색으로 나타납니다. 구성을 변경하지 않고 새로운 jdk를 설치하지 않았지만 Eclipse가 작동을 멈췄습니다.

내 eclipse.ini 파일은 다음과 같습니다.

--clean
-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20130327-1440.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20130807-1835
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vm
C:/Program Files (x86)/Java/jre7/bin/javaw.exe
--launcher.appendVmargs
-vmargs
-Dosgi.requiredJavaVersion=1.6
-Xms40m
-Xmx1024m

Eclipse를 성공적으로 시작하려면 제거했습니다.

    -vmargs
    -Dosgi.requiredJavaVersion=1.6
    -vm 
C:/Program Files (x86)/Java/jre7/bin/javaw.exe

그래서 여기 내 업데이트 파일이 있습니다 :

--clean
-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20130327-1440.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20130807-1835
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-Xms40m
-Xmx1024m

내 jvm 버전이 1.6이므로 osgi.requiredJavaVersion = 1.6을 제거하는 이유를 모르겠습니다. http://help.eclipse.org/indigo/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Freference%2Fmisc%2Fruntime-options.html 문서에서

osgi.requiredJavaVersion
The minimum java version that is required to launch Eclipse. The default value is "1.4.1".

내 Java 버전이 올바르게 설정되었다고 생각합니다. 어쨌든 이클립스가 지금 시작하고 나를 위해 달려갑니다 ...


다음과 같이 될 수도 있습니다.

-vm 
C:\Program Files\Java\jre6\bin\server\jvm.dll

-vm매개 변수를 추가하면 효과가 있습니다.

-vm 
C:\Program Files\Java\jdk1.7.0_45\jre\bin\server\jvm.dll

성공하지 않고 위의 모든 대답을 시도한 사람들은 -Xms 값을 낮추십시오. 이전 Eclipse (Weblogic Eclipse 10.3.6)를 지원해야합니다. Windows 7 시스템 및 Windows Server 2008 R2 Enterprise VM (아래 Java 버전은 32 비트 Java를 가리킴)에 다음 .ini가있었습니다. 일하고 완벽하게 일하고있었습니다.

-vm
C:/Java/Java7/jdk1.7.0_79/bin/javaw.exe
-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.200.v20120522-1813
-showsplash
org.eclipse.platform
--launcher.defaultAction
openFile
-vmargs
-Xms1024m
-Xmx1024m
-XX:MaxPermSize=256m
-Dsun.lang.ClassLoader.allowArraySyntax=true
-Dweblogic.home=C:/Oracle/Middleware/wlserver_10.3

So a 32-bit Java for a 32-bit Eclipse, but still exit code 1. Based on all answers I had seen here, and the only change being a new laptop with Windows 10, the only possible explanation was that the new OS and the Eclipse were disagreeing on something. So I started playing around with each of the values, and it worked when I lowered both Xms and Xmx to 512m. I have a hunch that possibly the new Windows OS is preventing a higher initial heap size based on some run condition (the higher -Xms does work on Windows 10 on all other similar devices I came across) - so any other explanation is welcome. Meanwhile following is the only value I tweaked to successfully launch Eclipse.

-Xms512m 

Working combinations of OS, JDK and eclipse bitness.

  • 32-bit OS , 32-bit JDK , 32-bit Eclipse (32-bit only)
  • 64-bit OS , 32-bit JDK , 32-bit Eclipse
  • 64-bit OS , 64-bit JDK , 64bit Eclipse (64-bit only)

Kindly use 1 of the above combinations.


I had same issue in my windows 7, 64-bit machine. Then I downloaded and installed 64 bit jdk for Java(which includes jre). This solved the issue.


I've encountered similar problems. The reason is that the path to my eclipse includes Chinese characters. Once those characters are deleted, the problem is solved. Please check if there are characters other than English in your path.


I too faced the similar issue , not solved after adding the command in eclipse.ini file. My root cause is different. I was experimenting on sequence diagrams using objectaid. This is throwing an exception and disturbed my workspace. You may have different issue when working on new plugins. Better you check the log file located in your project work-space C:\path\to\workspace\.metadata\.log


This can be resolved by adding the following line to the eclipse.ini file -XX:-UseCompressedOops


I had the same issue which was caused due to crash shutdown of my windows 10. Earlier in the path I had Oracle path ie the path inserted by Oracle at the time of installation of JDK. I removed it and changed the path to the JDK location. This solved the problem.


Mine is a 64 bit system with 64bit java installation. what worked for me was the following:

  1. Goto the eclipse installation directory
  2. right click the eclipse icon and click "send to desktop as shortcut"
  3. Then right click on the shortcut icon in the desktop and then > properties > shortcut tab
  4. In the target field point it to the correct java 64 bit installations home path using the vm argument with the java_home path enclosed in quotes like so :

    D:\Scala_eclipse\eclipse.exe -vm "C:\Program Files\Java\jdk1.8.0_11"

    스칼라 일식 바로 가기 아이콘

This almost always solves all my Eclipse (scala eclipse as well) related problems. As mentioned in the answer , please make sure you are using the right combination of eclipse and java


just to add here...
For the guys those who still couldn't start eclipse due same error, please check eclipse.ini file again and see have you forgot to put M after memory size. For example:

-Xmx1024
or
-Xmx1024MB
or
-Xmx1024 M
or
-Xmx1024 mb
or
-Xmx1024mb

are incorrect, it should be -Xmx1024M. I have been trying different ideas from SOF and from other forums, and in this cut/paste I forgot that I missed M (such a little thing to miss), so I thought I should share. If it works for some of you please up-vote.


I had this issue recently, but I hadn't changed any java or updated the java version, May be this issue happened because of crash shutdown of the system.

And after reading a couple of answers here I decided to change the java version from 1.6 to 1.7 in the eclipse.ini file.

-vmargs
-Dosgi.requiredJavaVersion=1.6  

After this change the Eclipse started well and it worked. Since I didnt had changed anything i decided to change it back to 1.6 to what it was originally.

Then I started eclipse and guess what it worked. So Looks like in my case just touching/modifiying the eclipse.ini file worked.

I hope this answer is helpful to somebody.


Directly changing eclipse file is not a good idea, no matter facet or ini, unless it could be changed in eclipse. Had the same problem, with jdk1.8 installed. Change it to jdk 1.7.여기에 이미지 설명을 입력하십시오

Besides, according to https://wiki.eclipse.org/Eclipse/Installation, both LUNA and MARS need 1.7. So just ensure you have it installed.


If none of the solutions works, please check if you have more than one version of java installed on your machine. Please keep only one version which you prefer and everything should work fine.


None of the above answers helped for me. I discovered that, in general, an error like that could mean that your eclipse.ini has an invalid entry. So, all the above answers could be correct, depending on your particular case. In my case, it turned out I added a locale argument with a typo in it.


I tried to change the path in the parameter -vm, but it did not help. Then I deleted the parameter -vm and -vmargs from the eclipse.ini. It worked for me


1) SpringToolSuite4.ini 파일을 엽니 다 .
2) openFile을 검색하십시오 .
3) SpringToolSuite4.ini에 jvm.dll 파일 위치를
제공하십시오. 4) 참고 : 아래에 표시된 것처럼 -vm과 jvm.dll 파일 위치 경로 사이에 줄 바꾸기를 제공하십시오.

openFile
-vm 
C:\Program Files\Java\jre8\bin\server\jvm.dll
-vmargs
-Dosgi.requiredJavaVersion=1.8
-Xms256m

여기에 이미지 설명을 입력하십시오


c : / program files / java / jre / bin / server / jvm.dll을 찾을 수 없으면 jdk 폴더에서 jre를 복사하여 jdk 폴더 외부에 붙여 넣으십시오. 그리고 다시 시도하십시오 ...

참고 URL : https://stackoverflow.com/questions/18609160/eclipse-returns-error-message-java-was-started-but-returned-exit-code-1

반응형