Teamprise Knowledge Base

TKB00026 Increasing the memory available to Eclipse

Last updated 2008-09-29 22:14:45 UTC by Edward Thomson

Introduction

It is usually neccessary to increase the amount of memory that the Java virtual machine running Eclipse uses. Eclipse is a memory-intensive application, and the default amount of memory is usually not enough. The available memory is increased by passing parameters to the Eclipse launcher executable.

Details

The eclipse launcher executable (for example, eclipse.exe on Windows) is responsible for launching a JVM process to host Eclipse. The parameters for increasing the available memory differ from JVM to JVM. The instructions given below are valid for Sun's JVMs.

The eclipse launcher executable takes a -vmargs parameter that allows for passing of JVM specific arguments to the JVM process. For example, the following invocation gives the general form of passing a -Xmx argument to the JVM to increase the maximum heap size:

    eclipse.exe [normal arguments] -vmargs -Xmx256M
    

The key is to pass -vmargs followed by the JVM-specific memory setting (usually -Xmx256M, replacing 256M with any size) as the final arguments to the Eclipse launcher.

Recommendations

It's best to run Eclipse with as much memory as you can, but at least 256 MB is recommended.

Windows Example

On windows, the easiest way to change this setting is to edit a shortcut that launches eclipse.exe. The following screenshot illustrates this approach:

Products affected:

  • Teamprise Plugin for Eclipse

Releases affected:

  • All

Platforms affected:

  • All

Related articles:

This article is referenced by these articles:

Keywords: memory heap OutOfMemoryError