Performance and scalability: The java application crash once a week

  1. The java application crash once a week (4 messages)

    I have a java application that crash once a week, very strange, and i have check it for weeks, and cannot find any bugs in the code, is that the JVM's bug? The java application is running on linux, slackware 10.1, kernel, SMP, NPTL. java version is 1.5.0_07. the command line is: -Xmx1224m -Xms1224m -Dcom.sun.management.jmxremote.port=1111 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false, when the application started, use the command top on linux, you can see: VIRT = 2223m RES = 1.2g SHR = 10m that means the virtual memory is about 2223m, but the VIRT will increase all along, about 1 week after the application started, the VIRT will increase to be almost 3g, when it reaches 3g, the application will crash(do not response any more, but the process is still there). i know the in the 32bit OS, one process's virtual memory cannot greater than 3g (64bit can) , but i am so confused , why the virtual memory in my application will always increased ? i have set the -Xmx to be 1224m, and i set my application's internal thread is always 1500, cannot increased, but why the virtual memory is still increased all the time ? it this the JVM's bug ? how can i solve this ?
  2. I think there is something wrong with your code, Did you try using Wily or jprobe ? it;s a excellent way to find any potential issues in code, of-course it will also show if there is a memory leak in JVM (which I think is highly Unlikely.) HTH Chetan Khandar
  3. Use jconsole before that...[ Go to top ]

    You have enabled jmx port. Why don't you try checking the memory usage with JConsole. How is the memory usage in the JConsole chart?. If JVM crashes it would generate a core dump or a hs_*.log. Can you post it here. 1. Check the memory usage of JVM using JConsole. 2. Check JVM PermSize in JConsole 3. Check if you are using any native code. ~Rajesh.B
  4. You said yourself that the process continues to run but is unresponsive, so how exactly does that equate to a crash? I'll give you a hint: it's not a JVM crash. You have a bug/bugs in your code. Run your app in a profiler and find where the object retention is happening.
  5. It might have run OOM[ Go to top ]

    Check your default console output for your application. You might have a message like "OutOfMemoryError" at some point. That's what make any new allocation fail. And also, don't trust "top". Use an utility like "jconsole" to peek on your memory utilisation. You might have some object leaking somewhere which keeps building up. Bogdan