Friday, August 7, 2015

  • Android studio 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.



     Android studio 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.

     

    For Android Studio 1.3 : (Method 1)

    Step 1 : Open gradle.properties file in your Android Studio project.
    Step 2 : Add this line at the end of the file
    org.gradle.jvmargs=-XX\:MaxHeapSize\=256m -Xmx256m

    Above methods seems to work but if in case it won't then do this (Method 2)

    Step 1 : Start Android studio and close any open project (File > Close Project).
    Step 2 : On Welcome window, Go to Configure > Settings.
    Step 3 : Go to Build, Execution, Deployment > Compiler
    Step 4 : Change Build process heap size (Mbytes) to 1024 and Additional build process to VM Options to -Xmx512m.
    Step 5 : Close or Restart Android Studio.



  • 0 comments:

    Post a Comment

    Copyright @ 2013 Code Snippets.