Avoiding tomcat crashes or do auto restarts?
Platform: Intel PIII, RedHat 8, IBMJava2-SDK-1.3.1-3.0, tomcat4-4.1.18-full.1jpp We have found that if we push the server too hard, the Java VM running tomcat crashes. I'm assuming it's running out of memory, or file descriptors, or somesuch. Does anyone have a solution to this type of problem? Config parameters that can be tuned? A watchdog process that will restart the Java VM if it crashes (ie. something like the apache httpd does)? A temporary problem caused by a restart is acceptable. Flatlining due to a VM crash isn't. - Steinar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Avoiding tomcat crashes or do auto restarts?
http://www.mail-archive.com/[EMAIL PROTECTED]/msg07206.html This maybe of help. Increasing the Memory allocated to the Java VM when it runs Tomcat is probably the solution. -Original Message- From: news [mailto:[EMAIL PROTECTED] Behalf Of Steinar Bang Sent: 18 August 2003 14:33 To: [EMAIL PROTECTED] Subject: Avoiding tomcat crashes or do auto restarts? Platform: Intel PIII, RedHat 8, IBMJava2-SDK-1.3.1-3.0, tomcat4-4.1.18-full.1jpp We have found that if we push the server too hard, the Java VM running tomcat crashes. I'm assuming it's running out of memory, or file descriptors, or somesuch. Does anyone have a solution to this type of problem? Config parameters that can be tuned? A watchdog process that will restart the Java VM if it crashes (ie. something like the apache httpd does)? A temporary problem caused by a restart is acceptable. Flatlining due to a VM crash isn't. - Steinar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Avoiding tomcat crashes or do auto restarts?
If you run java -X you should get a list of memory orientated options. -Original Message- From: news [mailto:[EMAIL PROTECTED] Behalf Of Steinar Bang Sent: 18 August 2003 14:33 To: [EMAIL PROTECTED] Subject: Avoiding tomcat crashes or do auto restarts? Platform: Intel PIII, RedHat 8, IBMJava2-SDK-1.3.1-3.0, tomcat4-4.1.18-full.1jpp We have found that if we push the server too hard, the Java VM running tomcat crashes. I'm assuming it's running out of memory, or file descriptors, or somesuch. Does anyone have a solution to this type of problem? Config parameters that can be tuned? A watchdog process that will restart the Java VM if it crashes (ie. something like the apache httpd does)? A temporary problem caused by a restart is acceptable. Flatlining due to a VM crash isn't. - Steinar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Avoiding tomcat crashes or do auto restarts?
Howdy, We have found that if we push the server too hard, the Java VM running tomcat crashes. I'm assuming it's running out of memory, or file descriptors, or somesuch. You can take one of two approaches, or even both together: - Write a little program that watches tomcat's PID (tomcat can write out its PID to a file you designate when it starts up, see $CATALINA_HOME/bin/catalina.sh for instructions), and if the PID is unavailable for a few seconds restarts tomcat. - Actually figure out when and why you're crashing, and tune your app and the server to handle that load. Increase memory and file descriptors as needed, figure out what your max capacity is on your current hardware, etc, ie actually do the work instead of covering everything with the above band-aid. A temporary problem caused by a restart is acceptable. Flatlining due to a VM crash isn't. I agree ;) I always tell my engineers, however, that an improperly benchmarked system is unacceptable as well, so that wouldn't even make it to production without a clear specification of its max load and required hardware/software configuration to support that load. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Avoiding tomcat crashes or do auto restarts?
- To tune some parameters you must investigate what causes the failure. Otherwise you will waste your time optimizing the wrong options. (If you look close enough at the complete system, there are several dozen of options where you can tune: io settings of the os, memory settings, bios settings, tcp/ip settings, java vm settings, tomcat settings, db settings) Most of te option depend on your application an the type of load it has to handle. - To do a restart on a VM crash is a good idea anyway. A good starting point could be: http://linux.oreillynet.com/pub/a/linux/2002/05/09/sysadminguide.html http://cr.yp.to/daemontools/faq/create.html#why (Although they don't talk about tomcat) -Original Message- From: Steinar Bang [mailto:[EMAIL PROTECTED] Sent: Monday, August 18, 2003 3:33 PM To: [EMAIL PROTECTED] Subject: Avoiding tomcat crashes or do auto restarts? Platform: Intel PIII, RedHat 8, IBMJava2-SDK-1.3.1-3.0, tomcat4-4.1.18-full.1jpp We have found that if we push the server too hard, the Java VM running tomcat crashes. I'm assuming it's running out of memory, or file descriptors, or somesuch. Does anyone have a solution to this type of problem? Config parameters that can be tuned? A watchdog process that will restart the Java VM if it crashes (ie. something like the apache httpd does)? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]