3 Replies Latest reply on Feb 12, 2002 7:02 PM by fellenberger

    Ignoring memory settings?

    jeffelysium

      I ran into an out of memory error with JBoss recently, and noticed that I hit the usual JDK ceiling of 64m. I have been trying to increase this value by modifying the run.bat file with the following changes:

      java %JAXP% -classpath "%JBOSS_CLASSPATH%" -Xms128M -Xmx256M org.jboss.Main %1 %2 %3 %4 %5 %6 %7 %8 %9

      However, the JDK appears to be ignoring these values. I am using JDK 1.3.1 on a Windows 2000 machine with JBoss 2.4.3. When I open task manager the initial memory is only 20megs (not the 128 I specified) and I continue to get the out of memory error at 64 megs.

      Does anyone have any suggestions on how I can get this to work?

      Thanks,
      -Jeff

        • 1. Re: Ignoring memory settings?

          That sounds strange?

          I used -Xmx2048K a lot when tracking down a memory leak
          in 2.4.3 (which is fixed for 2.4.4 by the way)

          Are you sure the command line is exactly as you
          posted it?

          Regards,
          Adrian

          • 2. Re: Ignoring memory settings?
            jeffelysium

            I think I figured it out - it appears to be just how task manager in win2k reports memory usage. (Though I don't understand how I got the out of memory error, but I'll see if I can replicate that).

            I am using this exact syntax (cut and paste from run.bat):

            java %JAXP% -classpath "%JBOSS_CLASSPATH%" -Xms128m -Xmx256m org.jboss.Main %1 %2 %3 %4 %5 %6 %7 %8 %9

            I also upgraded to 2.4.4 and the latest JVM. Task manager still reported less than the 128megs of memory. However, I found a free tool at http://www.sysinternals.com that let's you get a more detailed report. Using that tool the system reports "private bytes" of ~128megs. When I changed this to 256m, it worked reported that correctly as well.

            On Solaris, it looks as though it does report correctly, I was using: java -server -Xms1024m -Xmx2048m etc. and could see the memory stats as expected.

            Thanks,
            -Jeff

            • 3. Re: Ignoring memory settings?
              fellenberger

              Along the sames lines, if I try and allocate more than 64MB to the min and max heap (i.e. -Xms128m -Xmx256m) I get the following error during startup:
              -----------------------------------------------------
              Error occurred during initialization of VM
              Incompatible initial and maximum heap sizes specified
              Press any key to continue . . .
              -----------------------------------------------------
              I am using jdk131_01 on WinNT 4.0, with Jboss 2.4.4/Tomcat 3.2.3

              Any suggestions?