Results 1 to 5 of 5

Thread: Eclipse heap size set to 64M

  1. #1
    go2playgo NNTP User

    Question Eclipse heap size set to 64M

    Somehow the parameters in eclipse.ini are not recognized at all and the default heap size - 64M is used if I start from the KDE menu. I checked this with VisualVM.

    If I start it from a command as follows then it's recognized.
    eclipse -vmargs -Xmx256m

    Here is my eclipse.ini.
    -showsplash
    org.eclipse.platform
    -vmargs
    -Xmx256m
    -XX.MaxPermSize=128m

    I tried this one as well.
    -showsplash
    org.eclipse.platform
    --launcher.XXMaxPermSize
    256m
    -vmargs
    -Xmx256m

    SuSE 11.0 (32 bit)
    Eclipse 3.4.0 (installed from YaST)
    Java 1.6.0_u7

    Do you know why?

  2. #2
    ab@novell.com NNTP User

    Default Re: Eclipse heap size set to 64M

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    Here is mine from SLED 10 SP2 x86_64 (custom install of eclipse, btw):

    <quote filepath="/home/myuser/apps/eclipse/eclipse.ini">
    - -showsplash
    org.eclipse.platform
    - -framework
    plugins/org.eclipse.osgi_3.4.0.v20080605-1900.jar
    - -vmargs
    - -Dosgi.requiredJavaVersion=1.5
    - -Xms40m
    - -Xmx256m
    - -XX:MaxPermSize=256m
    </quote>

    Once running I see the Xmx and XX:MaxPermSize both in 'ps' output for
    the Java process. Under Help: About Eclipse: Configuration Details I
    also see the '256' values set. As a note I'm use a 1.6 JRE though I
    really doubt that matters.

    Good luck.





    go2playgo wrote:
    > Somehow the parameters in eclipse.ini are not recognized at all and the
    > default heap size - 64M is used if I start from the KDE menu. I checked
    > this with VisualVM.
    >
    > If I start it from a command as follows then it's recognized.
    > eclipse -vmargs -Xmx256m
    >
    > Here is my eclipse.ini.
    > -showsplash
    > org.eclipse.platform
    > -vmargs
    > -Xmx256m
    > -XX.MaxPermSize=128m
    >
    > I tried this one as well.
    > -showsplash
    > org.eclipse.platform
    > --launcher.XXMaxPermSize
    > 256m
    > -vmargs
    > -Xmx256m
    >
    > SuSE 11.0 (32 bit)
    > Eclipse 3.4.0 (installed from YaST)
    > Java 1.6.0_u7
    >
    > Do you know why?
    >
    >

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.2 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

    iD8DBQFJHYrj3s42bA80+9kRAk1nAJkBTZbayHRVblsLB6dT6OgeuYX94wCdEpOr
    9fCyp7Sq+PBXkX9wIJRFgms=
    =rpJI
    -----END PGP SIGNATURE-----

  3. #3
    go2playgo NNTP User

    Default Re: Eclipse heap size set to 64M

    I searched on the net and found that /etc/eclipse.conf can be updated to include the vmargs values and it works fine.

    VM_ARGS="-Xmx256m -XX:MaxPermSize=128m"

    Not sure why the parameters of eclipse.ini are ignored, but this bug seems interesting as it says the command-line parameters were now passed on 2008-05-22. My /usr/share/eclipse/eclipse shows as follows and the launcher shows it's made early May 2008.

    #!/bin/bash
    STARTUP_JAR="/usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar"
    /usr/share/eclipse/eclipse.bin -startup $STARTUP_JAR "$@"

    When I echoed $@ just before the last line it was showing "-vm /usr/lib/jvm/java/bin/java" only, no vmagrs.

    Anyway I'm happy now.

  4. #4
    ab@novell.com NNTP User

    Default Re: Eclipse heap size set to 64M

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    Good to hear. Thank-you for posting back your findings.

    Good luck.





    go2playgo wrote:
    > I searched on the net and found that /etc/eclipse.conf can be updated to
    > include the vmargs values and it works fine.
    >
    > VM_ARGS="-Xmx256m -XX:MaxPermSize=128m"
    >
    > Not sure why the parameters of eclipse.ini are ignored, but 'this bug'
    > (https://bugzilla.novell.com/show_bug.cgi?id=335552) seems interesting
    > as it says the command-line parameters were now passed on 2008-05-22. My
    > /usr/share/eclipse/eclipse shows as follows and the launcher shows it's
    > made early May 2008.
    >
    > #!/bin/bash
    > STARTUP_JAR="/usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar"
    > /usr/share/eclipse/eclipse.bin -startup $STARTUP_JAR "$@"
    >
    > When I echoed $@ just before the last line it was showing "-vm
    > /usr/lib/jvm/java/bin/java" only, no vmagrs.
    >
    > Anyway I'm happy now.
    >
    >

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.2 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

    iD8DBQFJH5a53s42bA80+9kRArDQAJ9xI14dyCMHW8TeATWmsX5/LVPGTgCfejyQ
    Vbe8v7dXEoynAA8WzbeUv2E=
    =d66Q
    -----END PGP SIGNATURE-----

  5. #5
    go2playgo NNTP User

    Default Re: Eclipse heap size set to 64M

    I thought I fixed the problem, but it's not.

    1. vmargs details of eclipse.conf are not recognised properly by Eclipse

    Although the xmargs parameters are displayed in the configuration details it is not part of "eclipse.vm". If as start Eclipse with vmargs options I can see it in eclipse.vm and confirmed that the heap and PermGen size are properly reflected in VisualVM.

    Configuration details from Eclipse with eclipse.conf
    *** System properties:
    eclipse.buildId=I20080617-2000
    eclipse.commands=-os
    linux
    -ws
    gtk
    -arch
    x86
    -showsplash
    -launcher
    /usr/lib/eclipse/eclipse
    -name
    Eclipse
    --launcher.library
    /usr/lib/eclipse/plugins/org.eclipse.equinox.launcher.gtk.linux.x86_1.0.100.v20080606/eclipse_1114b.so
    -startup
    /usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar
    -vm /usr/lib/jvm/java/bin/java
    -vmargs -Xmx256m -XX:MaxPermSize=128m
    -vm
    /usr/lib/jvm/java-1.6.0-sun-1.6.0.u7/jre/bin/../lib/i386/client/libjvm.so
    eclipse.ee.install.verify=false
    eclipse.home.location=file:/usr/lib/eclipse/
    eclipse.launcher=/usr/lib/eclipse/eclipse
    eclipse.product=org.eclipse.sdk.ide
    eclipse.startTime=1227169686165
    eclipse.vm=/usr/lib/jvm/java-1.6.0-sun-1.6.0.u7/jre/bin/../lib/i386/client/libjvm.so
    eclipse.vmargs=-Djava.class.path=/usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar

    Configuration details from Eclipse with xmargs options in a command
    *** System properties:
    eclipse.buildId=I20080617-2000
    eclipse.commands=-os
    linux
    -ws
    gtk
    -arch
    x86
    -showsplash
    -launcher
    /usr/lib/eclipse/eclipse
    -name
    Eclipse
    --launcher.library
    /usr/lib/eclipse/plugins/org.eclipse.equinox.launcher.gtk.linux.x86_1.0.100.v20080606/eclipse_1114b.so
    -startup
    /usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar
    -vm /usr/lib/jvm/java/bin/java
    -vm
    /usr/lib/jvm/java-1.6.0-sun-1.6.0.u7/jre/bin/../lib/i386/client/libjvm.so
    eclipse.ee.install.verify=false
    eclipse.home.location=file:/usr/lib/eclipse/
    eclipse.launcher=/usr/lib/eclipse/eclipse
    eclipse.product=org.eclipse.sdk.ide
    eclipse.startTime=1227170377496
    eclipse.vm=/usr/lib/jvm/java-1.6.0-sun-1.6.0.u7/jre/bin/../lib/i386/client/libjvm.so
    eclipse.vmargs=-Xmx256m
    -XX:MaxPermSize=128m
    -Djava.class.path=/usr/share/eclipse/./plugins/org.eclipse.equinox.launcher_1.0.100.v20080509-1800.jar

    2. PermGen OutOfMemory error still occurs even if the size is big.
    I tried even with 128M with maximum of 256M, but the build still failed. VisualVM shows that only 50M is used. What I'm running was the JasperReports (v3.1.2) sample build that runs all samples. If I run the task that failed separately no problem occurs.

    So, now I know I can pass the vmargs from the command option and I created a shortcut on my desktop and added the parameters in properties. It's pity that the PermGen outofmemory error, which seems to be annoying quite a few people, cannot be resolved easily.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •