java 以 64 位启动 Intellij-IDEA 时出现 Jvm 错误 -6
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/36222964/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Jvm error -6 while starting Intellij-IDEA in 64 bit
提问by nickraga87
I have a problem starting Intellij IDEA (15.0.3) in 64 bit mode. When clicking on the idea6.exe I get this error (Failed to create a JVM error code -6):
我在 64 位模式下启动 Intellij IDEA (15.0.3) 时遇到问题。单击idea6.exe 时出现此错误(无法创建JVM 错误代码-6):
This is my configuration:
这是我的配置:
System:
Windows 7 - 64 bit - 16GB RAM
System Variables:
IDEA_JDK_64: C:\Program Files\Java\jdk1.8.0_74 JVM_HOME: C:\Program Files\Java\jdk1.7.0_79 (1.7 version is needed for my dev activity)
vm options: idea64.exe.vmoptions left as default
系统:
Windows 7 - 64 bit - 16GB RAM
系统变量:
IDEA_JDK_64: C:\Program Files\Java\jdk1.8.0_74 JVM_HOME: C:\Program Files\Java\jdk1.7.0_79 (1.7 version is needed for my dev activity)
vm 选项:idea64.exe.vmoptions 保留为默认值
As a trial: I've tried various combinations like system variables pointing to the same JDK path or also to increase -Xmx value in idea64.exe.vmoptions, but the error is still there.
作为试验:我尝试了各种组合,例如系统变量指向相同的 JDK 路径,或者增加 idea64.exe.vmoptions 中的 -Xmx 值,但错误仍然存在。
What can the root cause be?
根本原因可能是什么?
Thank you very much.
非常感谢你。
回答by VladVin
I solved problem in my case by deleting file C:\Users\username\.IdeaIC2016.2\idea.exe.vmoptions, because I created it before to customize VM options. File can have name idea64.exe.vmoptionsif you overrode options under 64-bit version of Intellij IDEA.
我通过删除文件C:\Users\username\.IdeaIC2016.2\idea.exe.vmoptions解决了我的问题,因为我之前创建了它来自定义 VM 选项。如果您在 64 位版本的 Intellij IDEA 下覆盖选项,则文件可以具有名称idea64.exe.vmoptions。
回答by David
Tracked it down to a mis-typed VM option in the end.
最后将其追踪到输入错误的 VM 选项。
Somehow one of the lines in my idea64.exe.vmoptions file has been mis-typed. Instead of -XX:UseParNewGC
I had -XX:USeParNewGC
(note the unwanted extra capital letter).
不知何故,我的idea64.exe.vmoptions 文件中的其中一行输入错误。而不是-XX:UseParNewGC
我有-XX:USeParNewGC
(注意不需要的额外大写字母)。
Correcting that fixed the problem - so check your .vmoptions file for typos if you get the -6 error on startup.
更正可以解决问题 - 如果您在启动时遇到 -6 错误,请检查您的 .vmoptions 文件是否有拼写错误。
And note that there may be several copies of this file. The default is in the installation folder (eg "Program Files (x86)\Jetbrains\Intellij 2016.1\bin\idea64exe.vmoptions"), but if you select "Help...Edit Custom VM Options" in the IDE it will create an override file in \Users\.IntellijIdea2016.1\idea64exe.vmoptions
请注意,此文件可能有多个副本。默认位于安装文件夹中(例如“Program Files (x86)\Jetbrains\Intellij 2016.1\bin\idea64exe.vmoptions”),但是如果您在 IDE 中选择“Help...Edit Custom VM Options”,它将创建一个\Users\.IntellijIdea2016.1\idea64exe.vmoptions 中的覆盖文件
回答by TJ.
I experienced the same issue with IntelliJ IDEA 2016.1.3 on 64bit Windows 7 with JDK1.8.0_92.
我在使用 JDK1.8.0_92 的 64 位 Windows 7 上使用 IntelliJ IDEA 2016.1.3 遇到了同样的问题。
Executing idea.bat
instead of idea.exe
worked for me.
执行idea.bat
而不是idea.exe
对我来说有效。
回答by Stanislav Demianets
I think issue caused because you are using 32 bit launcher, and it has limitation as 4G for RAM.
我认为问题是因为您使用的是 32 位启动器,并且它的 RAM 限制为 4G。
So, if you will change value "-Xmx" to 2048 in c:\users\XXXXXX.WebStorm2016.3\webstorm.exe file -> this should help. Otherwise -> delete this file and wait when WebSrotm propose you to change it from IDE
因此,如果您将 c:\users\XXXXXX.WebStorm2016.3\webstorm.exe 文件中的值“-Xmx”更改为 2048 -> 这应该会有所帮助。否则 -> 删除此文件并等待 WebSrotm 建议您从 IDE 更改它
Note: there are also webstorm.exe and webstorm64.exe files in your c:\Program Files
注意:c:\Program Files 中还有 webstorm.exe 和 webstorm64.exe 文件
回答by oche
For me, using Intelli J Idea Community Version 2017.3, I found the idea.exe.vmoptions file in C:\Users\${UserName}.IdeaIC2017.3\config. I had increased the JVM Heap Memory to 4096MB from 512MB due to an earlier crash (-Xmx4096m). Changing to 1024MB seemed to do the job.
对我来说,使用 Intelli J Idea Community Version 2017.3,我在 C:\Users\${UserName}.IdeaIC2017.3\config 中找到了 idea.exe.vmoptions 文件。由于较早的崩溃 (-Xmx4096m),我已将 JVM 堆内存从 512MB 增加到 4096MB。更改为 1024MB 似乎可以完成这项工作。
回答by Ajith Kannan
For me it worked once i deleted the vmoptions file created under the C:USERS.IntelliJIdea2017.2\config folder.
对我来说,一旦我删除了在 C:USERS.IntelliJIdea2017.2\config 文件夹下创建的 vmoptions 文件,它就起作用了。
回答by Pavlus
Had same problem, any option in studio64.exe.vmoptions
led to this window.
有同样的问题,任何选项都会studio64.exe.vmoptions
导致这个窗口。
Fixed by changing entry in PATH
, it had old JDK
folder, which pointed to different Java installation(Java 7) than JAVA_HOME
(Java 8), after replacing it — Android Studio started normally with entries in studio64.exe.vmoptions
file.
通过更改 中的条目来修复PATH
,它有旧JDK
文件夹JAVA_HOME
,在替换它之后指向不同的 Java 安装(Java 7)和(Java 8)——Android Studio 以studio64.exe.vmoptions
文件中的条目正常启动。