Mengatasi Error:Unable to start the daemon process Gradle

Publish Date : 29-10-2018 , dibaca 9251 kali, Hari ini dibaca : 1 kali ,0 comments

Anda mungkin pernah menjumpai masalah seperti ini saat membuat aplikasi android pada Android Studio , terlebih anda sering mendownload sample project di internet, nah terkadang project yang dibuat dari programer menggunakan versi gradle yang berbeda, nah berikut ini merupakan solusinya:

Android Studio Gradle project “Unable to start the daemon process /initialization of VM”

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

Nah pada tutorial kali , mari ikuti , untuk mengatasi masalah diatas :

The work solution for me , ok..

For android studio 2.2 version VM option is not available directly from project structure.

steps to make gradle sync successful:->

1)OPEN project

2)Click on gradle script

3)open gradle.properties

4)Change org.gradle.jvmargs=-Xmx1536m to org.gradle.jvmargs=-Xmx1024m , lihat script dibawah ini :

# Project-wide Gradle settings.

# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.

# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html

# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
#org.gradle.jvmargs=-Xmx1536m
org.gradle.jvmargs=-Xmx1024m
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true

5)Save the work

6)Open File->Invalidate cache/Restart

And its done!!!

Enjoy Android!!!

 

Produk Rekomendasi

Artikel Terkait

Diskusi



wa