So today I tried to run my PHPStorm7 IDE and I got this error :
I get a “Failed to create JVM error”; how can I avoid it?
I found this related issue, but it didn’t help me.
So i just fixed my problem thanks to @lena :
Edit the Phpstorm.exe.vmoptions file (IDE_HOME\bin\Phpstorm.exe.vmoptions) :
-Xms128m -Xmx2048m -XX:MaxPermSize=250m -XX:ReservedCodeCacheSize=64m -XX:+UseCodeCacheFlushing -ea -Dsun.io.useCanonCaches=false
And reduce -Xmx value step by step reducing by 100m every time until it starts.
This is JVM problem; Oracle JVM requires a single chunk of continuous memory (more or less equal to the sum of Xmx and XX:MaxPermSize parameters values) to initialize. On Windows systems 32-bit java can only allocate up to 1.5 Gb. And any libraries that inject themselves into process memory will reduce this solid block.
You can try to cleanup your system and uninstall/disable as many of such autoloading stuff as possible (context menu extensions, residental programs that can intercept global keys (e.g. Translator/Dictionary, IM, fraps, some graphic drivers have “hot keys” etc etc). The PhpStorm.exe launcher can itself cause additional fragmentation, thus I’d suggest using PhpStorm.bat instead.
see also https://jetbrains.zendesk.com/entries/23393413 for some hints
Probably you were using 64bit version as me, if so change the shortcut launcher from
This worked for me without any other trick.
I had the same problem after updating my computer (Ubuntu), I solve this issue by removing the line -XX:MaxPermSize=350m