java - Android Studio - Unrecognized VM option 'MaxPermSize=256m' -


i installed android studio on elementary os 0.3 freya , run using terminal. on first start-up, however, there's error message shown:

gradle 'test' project refresh failed

unable start daemon process. problem might caused incorrect configuration of daemon. example, unrecognized jvm option used. please refer user guide chapter on daemon @ http://gradle.org/docs/2.2.1/userguide/gradle_daemon.html please read following process output find out more:

unrecognized vm option 'maxpermsize=256m' error: not create java virtual machine. error: fatal exception has occurred. program exit.

i read this , tried ways solve no avail. did notice error different mine , thought might why couldn't solve problem using ways suggested.

as executed .sh file on terminal, printed:

java hotspot(tm) server vm warning: ignoring option maxpermsize=250m; support removed in 8.0

(java:5094): gtk-warning **: unable locate theme engine in module_path: "pixmap"

gtk-message: failed load module "canberra-gtk-module"

i'm not sure whether it's related error or not. please help.

as said in thread, permanent generation removed in java 8, used in case. think, easiest solution remove parameters associated permanent generation during program execution.

go directory have android studio. go bin/ subdirectory. locate following files, contains java virtual machine options:

  • studio.vmoptions
  • studio64.vmoptions

open these files , locate line maxpersize parameter. should follows:

xx:maxpermsize=256m

remove line in both files. don't know if using 32-bit or 64-bit operating system, can update both files in case.

i'm not sure if solve problem, try in such situation. in case, option , java 8, warning, android studio starts anyway. after removing parameter, android studio still starts, without warning. i'm using ubuntu 14.04 lts.

edit:

there solution problem described here: https://stackoverflow.com/a/27913562/1150795.

go file > other settings > default project structure > jdk location , check path.

in case of ubuntu linux, can set /usr/lib/jvm/java-7-oracle default jdk if using oracle jvm. jdk 7 safest option android.


Comments

Popular posts from this blog

Android : Making Listview full screen -

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -