简体   繁体   中英

android studio Error:Unable to start the daemon process

Version of Android Studio 2.2 OS version: Windows 10 Java JRE/JDK version: 1.8.0_51

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
https://docs.gradle.org/2.14.1/userguide/gradle_daemon.html Please
read the following process output to find out more:
----------------------- Error occurred during initialization of VM Could not reserve enough space for 1572864KB object heap

Im using Android studio version 2.2.2 on win 10 (32 bit) and this is how i fix this issue:

  1. Open your newly created project.
  2. Now open gradle.properties and change the JVM argument. ie org.gradle.jvmargs=-Xmx1024m Basically it comes with default value of -Xm1536m which somehow is not working (at least for me).
  3. Then Rebuild the project and it should work.

add this line instead of following line in gradle.properties file

comment this line #org.gradle.jvmargs=-Xmx1536m

add this line

org.gradle.jvmargs=-Xmx512m -XX:MaxPermSize=512m

尝试从C:\\Users\\<username>目录中删除.gradle ,然后重试。

In your project file\\platforms\\android\\cordova\\lib\\builders\\GradleBuilder.js Search for args.push and search for the line with the below description. Mine was Xmx2048m. I changed to Xmx1024m and it worked. 16MB of RAM in my pc. Change

args.push('-Dorg.gradle.jvmargs=-Xmx1024m'); 

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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