aspose file tools*
The moose likes Java in General and the fly likes Increase JVM heap size of eclipse Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Increase JVM heap size of eclipse" Watch "Increase JVM heap size of eclipse" New topic
Author

Increase JVM heap size of eclipse

dila peerbux
Greenhorn

Joined: Dec 30, 2007
Posts: 5
Hi,
Can anyone please tell me on how i can increase the heap size of eclipse?when running a program i am getting the error as follows:

Loading...
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space


Thank you in advance!!
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14272
    
  21

Use the -Xmx command line switch. Specifically for Eclipse, do this:

eclipse.exe -vmargs -Xmx512M

This gives Eclipse a maximum of 512 MB memory.

Note: I am assuming you want to give the Eclipse IDE itself more memory. If this isn't an issue with the IDE itself but with your own program which you are launching from the IDE, then you'll need to do something different: Select Run / Open Run Dialog, then select the configuration for launching your application. Click the Arguments tab, and in the box "VM arguments" add something like "-Xmx256M" to give your application 256 MB of memory.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Increase JVM heap size of eclipse