5 Replies Latest reply on Jan 11, 2010 11:28 AM by peterj

    Jboss is crashing and  throwing Out of swap space error.

    dmouli
      Hi,
      We have  deployed our product in jboss4.02  server in windows environment.
      we are getting the following exception while hitting the server with 5 concurrent requests.
      Exception in thread "CompilerThread0" java.lang.OutOfMemoryError: requested 1383
      13736 bytes for Chunk::new. Out of swap space?
      Press any key to continue . . .
      It is working fine with single request and failing in multi user environment only.
      We deployed the same jboss with our application in Linux  environment it is working fine and it is not crashing.
      And also we deployed  the same application in WEB LOGIC  server in Windows environment , it is working fine with out any crashes for n number users.
      Please help us to resolve the issue.
      Thanks in advance
      Mouli.D
        • 1. Re: Jboss is crashing and  throwing Out of swap space error.
          erasmomarciano

          Did you set anything on the JVM?

          • 2. Re: Jboss is crashing and  throwing Out of swap space error.
            dmouli

            Hi Thanks for ur response,

             

            These are the jvm options we have given.

             

            JAVA_OPTS: -server -Xmx768M -Dprogram.name=run.bat -Xms512m -Xmx1024m -Xss512k

             

            Server machine conguration :-

            4 GB ram,Windows 2003 server,Xeon dual CPU.

            • 3. Re: Jboss is crashing and  throwing Out of swap space error.
              peterj

              The OOME exception you are seeing could be caused by one of two things :

               

              a) The JVM is attempting ot expand the heap and Windows says it has no more memory available

              b) The JVM is attempting to spawn a new thread and Windows says it can't due to memory limitations

               

              Are you by any chance booting the Windows system with the /3G option? This can often lead to situation 'b' above.

               

              How large is your page file? What is your memory usage like, particularly committed memory?

               

              Are you ruinng a 32-bit or 64-bit OS?

               

              Try running with -Xms and -Xmx set to the same value (that is recommended for production anyway).

              • 4. Re: Jboss is crashing and  throwing Out of swap space error.
                dmouli

                Hi Peter Johnson,

                Thank u  for your response.

                 

                1.We tried with -Xms and -Xmx set to the same value then also same problem.

                2.We tried both 32, 64 bit systems then also same problem.

                3.We increased virtual memory also, no use.

                4.We have'nt used /3G option. (we are not aware of this)

                5. Same  jboss environment is working fine in LINUX environment, with out any crashes.

                6.Same application is working fine in Web-Logic and Windows environment.(I think the problem with the combination of jboss and Windows, is it right??)

                ..

                Thanks

                Mouli.D

                • 5. Re: Jboss is crashing and  throwing Out of swap space error.
                  peterj

                  Looking a little more carefully at the error message I notice that it is the compiler thread that is throwing the OOME. What is the size or the perngen? You might try increasing its max size, say to 512MB: -XX:MaxPermGen=512M

                   

                  Also, I juts now read an aarticle about a new sysinternals tool: vmmap. You might try using that and see if it provides and other clues.