Could not create the Java Virtual Machine

I am getting the following errors all the time. After I restart the visual studio the errors go away for 5 minutes, but most definitely come back.
Error 1 () Error: Could not create the Java Virtual Machine.
C:\Program Files (x86)\MSBuild\RemObjects Software\Oxygene\RemObjects.Oxygene.Cooper.Android.targets 94

Error 3 (AP1) Error while running Android tool: dx.bat C:\Program Files (x86)\MSBuild\RemObjects Software\Oxygene\RemObjects.Oxygene.Cooper.Android.targets 94

That sounds like “not enough memory”, is this by any chance a low memory machine (say less than 1 gb free?); Do you use the 32 or 64bits JVM? The 32bits Java works best.

This is a 16Gb of RAM machine with SSD. I think I just found the solution to this one: http://stackoverflow.com/questions/22225777/i-o-error-connection-refused-android-studio

I have new asus hardware and as soon as I kill the asus processes I no longer get an error. Please mark this one as resolved. Thank you

1 Like