Error Could not create the Java Virtual Machine

Error Could not create the Java Virtual Machine

If you are getting Could not create java virtual machine it means exe file is trying to search JAVA_OPTIONS and not finding it in the system.

To set its value please follow below steps:

  • Click start –> Right click Computer — Properties

Error Could not create the Java Virtual Machine

  • Click Advanced System settings –> Environment variables

Error Could not create the Java Virtual Machine

  • Click New to create JAVA_OPTIONS

Error Could not create the Java Virtual Machine

  • For Variable name: _JAVA_OPTIONS
  • Variable value: -Xmx512M ( Or based on your requirement and total memory)

Error Could not create the Java Virtual Machine

  • Click OK –> OK

After setting above you still get below exception:

Error occurred during initialization of VM
Incompatible minimum and maximum heap sizes specified
Picked up _JAVA_OPTIONS: -Xmx512M

It means size which we have specified correctly please go with this:

-Xms512m -Xmx512m

Error Could not create the Java Virtual Machine

  • Now start program again issue should be fixed. For more information please visit oracle forumĀ here

Leave a Reply

Your email address will not be published. Required fields are marked *