Error: Could not create the Java Virtual Machine.
2014-05-07 13:25
567 查看
最近使用Android Studio开发Android应用时,将studio更新到最新版后,就出错了。出错信息如下:
![](https://img-blog.csdn.net/20140507131501093?watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvdTAxMDEwMjE2Mg==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/Center)
Error:Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at http://gradle.org/docs/1.11/userguide/gradle_daemon.html
Please read below process output to find out more:
-----------------------
Error occurred during initialization of VM
Could not reserve enough space for object heap
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
在网上找了很久,且最近看了本关于JVM的书,终于弄明白了点,找到了解决办法。
开发环境:(32位)win7旗舰版 ;内存3G ;JDK1.7 ;JVM是HotSpot。(win+R -> cmd ->java -version会显示出jdk版本和jvm的信息)
主要是因为jvm无法无法向系统申请到想要的内存(可能是连续的内存吧)。
开始用这软件的时候,一切配置都是默认的。在StackOverFlow网站上找到了一篇说到的,将VM Options那里写上java虚拟机参数(我的设为-Xmx512m)。
(Android Studio上的设置方法:Ctrl+Alt+S,左边Project Settings下的Compiler -> Gradle -> VM Options 那一栏填上合适的参数。
网上搜索下HotSpot虚拟机的参数设置)
这个方法并不是万能的,将参数设小点容易成功。比如 -Xmx64m 。
Error:Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at http://gradle.org/docs/1.11/userguide/gradle_daemon.html
Please read below process output to find out more:
-----------------------
Error occurred during initialization of VM
Could not reserve enough space for object heap
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
在网上找了很久,且最近看了本关于JVM的书,终于弄明白了点,找到了解决办法。
开发环境:(32位)win7旗舰版 ;内存3G ;JDK1.7 ;JVM是HotSpot。(win+R -> cmd ->java -version会显示出jdk版本和jvm的信息)
主要是因为jvm无法无法向系统申请到想要的内存(可能是连续的内存吧)。
开始用这软件的时候,一切配置都是默认的。在StackOverFlow网站上找到了一篇说到的,将VM Options那里写上java虚拟机参数(我的设为-Xmx512m)。
(Android Studio上的设置方法:Ctrl+Alt+S,左边Project Settings下的Compiler -> Gradle -> VM Options 那一栏填上合适的参数。
网上搜索下HotSpot虚拟机的参数设置)
这个方法并不是万能的,将参数设小点容易成功。比如 -Xmx64m 。
相关文章推荐
- 启动eclipse时候提示错误Error:Could not create the Java Virtual Machine. Error:A Fatal exception has occurred
- Java出错 Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred .Pro
- Java出错 Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred
- kettle启动“Error: could not create the Java Virtual Machine”
- error could not create the java virtual machine.error:a fatal exception has occurred...问题之解决
- eclipse启动报错:Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred
- Error: Could not create the Java Virtual Machine.
- Error: Could not create the Java Virtual Machine
- weblogic10.3 启动报错 Unrecognized option: -jrockit Error: Could not create the Java Virtual Machine
- kettle启动“Error: could not create the Java Virtual Machine”
- Android Studio Error -- Could not create the Java Virtual Machine
- Scala compile server Error: Could not create the Java Virtual Machine.Error: A fatal exception
- IDEA 运行测试报错 Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred.
- 制作ota升级包之error:Could not create the Java virtual machine
- Error:Could not create the Java Virtual Machine. Error:A Fatal exception has occurred,程序将退出。
- 解决eclipse启动报错 Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred
- Java出错 Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred
- 报错 Error:Could not create the Java Virtual Machine
- eclipse启动报错:Error:Could not create the Java Virtual Machine Error:A fatal exception has occurred
- java virtual machine launcher Error:Could not create the Java Virtual Machine. Error:A Fatal exception has occurred,Program will exit.