Re: Tomcat Boot: Help!
My script: --- #!/bin/sh # # Start/Stop Jakarta Tomcat # Source function library . /etc/rc.d/init.d/functions export PATH=$PATH:/usr/java/jdk1.3.0_02/bin export JAVA_HOME=/usr/java/jdk1.3.0_02 export TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 case $1 in start) echo -n Starting tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start echo touch /var/lock/subsys/tomcat ;; stop) echo -n Shutting down tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat stop echo rm -f /var/lock/subsys/tomcat rm -f /var/run/tomcat.pid ;; restart) $0 stop sleep 2 $0 start ;; *) echo Usage: $0 {start|stop|restart} exit 1 esac exit 0 --- I have used other scripts as well, some that use su, some that just call /usr/java/jakarta-tomcat-3.2.1/bin/tomcat.sh...none of them have worked. I get the same results every time. Tomcat appears to start (from reading the logs) but then mysteriously dies before I can run ps aux. The script is currently in /etc/rc.d/init.d with symbolic links in the various rcx.d directories pointing to it. When I run the script from the command line, it works properly, but not while the system is booting. What distro are you using, and what versions of Tomcat, Apache, JDK are you using, if you don't mind me asking? MGRUBER - Original Message - From: Darrell Porter [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, May 01, 2001 6:38 PM Subject: RE: Tomcat Boot: Help! What does your script look like? Where is it? -Original Message- From: Mike Gruber [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 01, 2001 10:17 AM To: [EMAIL PROTECTED] Subject: Tomcat Boot: Help! I am still desperately trying to get Tomcat 3.2.1 to start up at boot time. It starts, but then dies before the login. Running the exact same init script from the command line works no problem, so I am completely at a loss as to the cause of the problem. I am so desperate, I am even willing to completely change Linux distributions if anyone out there knows a distro that works with Tomcat. I am currently using Caldera eServer 2.3 with jdk1.3.0_02 and apache 1.3.19. Please reply to this post and tell me what distribution, versions, etc you are using to make tomcat load at boot time. Any and all information will be greatly appreciated. MGRUBER
Tomcat Boot: Help!
I am still desperately trying to get Tomcat 3.2.1 to start up at boot time. It starts, but then dies before the login. Running the exact same init script from the command line works no problem, so I am completely at a loss as to the cause of the problem. I am so desperate, I am even willing to completely change Linux distributions if anyone out there knows a distro that works with Tomcat. I am currently using Caldera eServer 2.3 with jdk1.3.0_02 and apache 1.3.19. Please reply to this post and tell me what distribution, versions, etc you are using to make tomcat load at boot time. Any and all information will be greatly appreciated. MGRUBER
Tomcat Init at Boot
I am currently using the binary versions of Tomcat 3.2.1 and JDK 1.3.0_02 on Caldera eServer 2.3. I have placed a tomcat init script in the init.d directory (see script below) and linked to in from the various rcx.d dirs. My problem is that the script is being run during the boot sequence, but Tomcat never starts. If I run the exact same script from the command line (as root) however, Tomcat starts no problem. The log files aren't reporting any noticeable errors when Tomcat fails to load at boot, so I am unsure what the discrepancy is between init running the script and the root user running the script. Any information or advice anyone can give me on this problem will be greatly appreciated. MGRUBER ps - I have tried other init scripts and I get the same result with them all. Here is the latest version: --- #!/bin/sh # # Start/Stop Jakarta Tomcat # Source function library . /etc/rc.d/init.d/functions export PATH=$PATH:/usr/java/jdk1.3.0_02/bin export JAVA_HOME=/usr/java/jdk1.3.0_02 export TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 case $1 in start) echo -n Starting tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start echo touch /var/lock/subsys/tomcat ;; stop) echo -n Shutting down tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat stop echo rm -f /var/lock/subsys/tomcat rm -f /var/run/tomcat.pid ;; restart) $0 stop sleep 2 $0 start ;; *) echo Usage: $0 {start|stop|restart} exit 1 esac exit 0 ---
Tomcat Init At Boot
I am currently using the binary versions of Tomcat 3.2.1 and JDK 1.3.0_02 on Caldera eServer 2.3. I have placed a tomcat init script in the init.d directory (see script below) and linked to in from the various rcx.d dirs. My problem is that the script is being run during the boot sequence, but Tomcat never starts. If I run the exact same script from the command line (as root) however, Tomcat starts no problem. The log files aren't reporting any noticeable errors when Tomcat fails to load at boot, so I am unsure what the discrepancy is between init running the script and the root user running the script. Any information or advice anyone can give me on this problem will be greatly appreciated. MGRUBER ps - I have tried other init scripts and I get the same result with them all. Here is the latest version: --- #!/bin/sh # # Start/Stop Jakarta Tomcat # Source function library . /etc/rc.d/init.d/functions export PATH=$PATH:/usr/java/jdk1.3.0_02/bin export JAVA_HOME=/usr/java/jdk1.3.0_02 export TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 case $1 in start) echo -n Starting tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start echo touch /var/lock/subsys/tomcat ;; stop) echo -n Shutting down tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat stop echo rm -f /var/lock/subsys/tomcat rm -f /var/run/tomcat.pid ;; restart) $0 stop sleep 2 $0 start ;; *) echo Usage: $0 {start|stop|restart} exit 1 esac exit 0 ---
Re: Tomcat Init At Boot
Here is the contents of rc.out: -- + export PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/java/jdk1.3.0_02/bin + PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/java/jdk1.3.0_02/bin + export JAVA_HOME=/usr/java/jdk1.3.0_02 + JAVA_HOME=/usr/java/jdk1.3.0_02 + export TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 + TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 + echo -n Starting tomcat: Starting tomcat: + daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start + [ 1 != 1 ] + daemon=/usr/java/jakarta-tomcat-3.2.1/bin/tomcat start + shift ++ basename /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start + name=tomcat + [ tomcat = /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start ] + ssd -S -n tomcat -x /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start -- tomcatUsing classpath: /usr/java/jakarta-tomcat-3.2.1/lib/ant.jar:/usr/java/jakarta-tomcat-3.2.1/li b/jasper.jar:/usr/java/jakarta-tomcat-3.2.1/lib/jaxp.jar:/usr/java/jakarta-t omcat-3.2.1/lib/parser.jar:/usr/java/jakarta-tomcat-3.2.1/lib/servlet.jar:/u sr/java/jakarta-tomcat-3.2.1/lib/test:/usr/java/jakarta-tomcat-3.2.1/lib/web server.jar:/usr/java/jdk1.3.0_02/lib/tools.jar + echo + touch /var/lock/subsys/tomcat + exit 0 Starting tomcat. Check logs/tomcat.log for error messages -- and here is the contents of logs/tomcat.log: -- 2001-04-25 11:43:52 - ContextManager: Adding context Ctx( /examples ) 2001-04-25 11:43:52 - ContextManager: Adding context Ctx( /admin ) 2001-04-25 11:43:52 - ContextManager: Adding context Ctx( ) 2001-04-25 11:43:52 - ContextManager: Adding context Ctx( /test ) -- The timestamp is the same for both files, so it looks as though Tomcat is starting, but could something else loading in the boot sequence be killing it? The other files listed in rc5.d (after S84tomcat) are: S85httpd S88squid S91samba S92iBCS S95news S98local S99bigfs S99rmnologin S99skipped S99zap Any ideas? MGRUBER - Original Message - From: Boyce, David [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, April 25, 2001 11:24 AM Subject: RE: Tomcat Init At Boot The Tomcat logfiles are presumably not showing anything because the failure happens before Tomcat starts up. Try adding the following line at the top of your rc script: exec /tmp/rc.out 21 set -x And take a look at /tmp/rc.out after a reboot. You should see the failure. -David Boyce -Original Message- From: Mike Gruber [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 25, 2001 12:07 PM To: [EMAIL PROTECTED] Subject: Tomcat Init At Boot I am currently using the binary versions of Tomcat 3.2.1 and JDK 1.3.0_02 on Caldera eServer 2.3. I have placed a tomcat init script in the init.d directory (see script below) and linked to in from the various rcx.d dirs. My problem is that the script is being run during the boot sequence, but Tomcat never starts. If I run the exact same script from the command line (as root) however, Tomcat starts no problem. The log files aren't reporting any noticeable errors when Tomcat fails to load at boot, so I am unsure what the discrepancy is between init running the script and the root user running the script. Any information or advice anyone can give me on this problem will be greatly appreciated. MGRUBER ps - I have tried other init scripts and I get the same result with them all. Here is the latest version: --- #!/bin/sh # # Start/Stop Jakarta Tomcat # Source function library . /etc/rc.d/init.d/functions export PATH=$PATH:/usr/java/jdk1.3.0_02/bin export JAVA_HOME=/usr/java/jdk1.3.0_02 export TOMCAT_HOME=/usr/java/jakarta-tomcat-3.2.1 case $1 in start) echo -n Starting tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat start echo touch /var/lock/subsys/tomcat ;; stop) echo -n Shutting down tomcat: daemon /usr/java/jakarta-tomcat-3.2.1/bin/tomcat stop echo rm -f /var/lock/subsys/tomcat rm -f /var/run/tomcat.pid ;; restart) $0 stop sleep 2 $0 start ;; *) echo Usage: $0 {start|stop|restart} exit 1 esac exit 0 ---