Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@apache.org Received: (qmail 22950 invoked from network); 16 Feb 2003 23:38:27 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 16 Feb 2003 23:38:27 -0000 Received: (qmail 14586 invoked by uid 97); 16 Feb 2003 23:40:06 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-user@nagoya.betaversion.org Received: (qmail 14579 invoked from network); 16 Feb 2003 23:40:06 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 16 Feb 2003 23:40:06 -0000 Received: (qmail 21525 invoked by uid 500); 16 Feb 2003 23:38:14 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 21511 invoked from network); 16 Feb 2003 23:38:13 -0000 Received: from smtp-relay-3.adobe.com (HELO smtp-relay-3.sea.adobe.com) (192.150.22.10) by daedalus.apache.org with SMTP; 16 Feb 2003 23:38:13 -0000 Received: from inner-relay-3.corp.adobe.com (inner-relay-3 [153.32.251.51]) by smtp-relay-3.sea.adobe.com (8.12.3/8.12.3) with ESMTP id h1GNbsQJ009057 for ; Sun, 16 Feb 2003 15:38:04 -0800 (PST) Received: from mailsj-v1.corp.adobe.com (mailsj-dev.corp.adobe.com [153.32.1.192]) by inner-relay-3.corp.adobe.com (8.12.3/8.12.3) with ESMTP id h1GNbstX028521 for ; Sun, 16 Feb 2003 15:37:55 -0800 (PST) From: jmong@adobe.com Received: from adobe.com ([127.0.0.1]) by mailsj-v1.corp.adobe.com (Netscape Messaging Server 4.15 v1 Jul 11 2001 16:32:57) with ESMTP id HAFDN600.O1J for ; Sun, 16 Feb 2003 15:37:54 -0800 To: "Tomcat Users List" Message-ID: <1a3dd1e8a8.1e8a81a3dd@adobe.com> Date: Sun, 16 Feb 2003 15:37:54 -0800 X-Mailer: Netscape Webmail MIME-Version: 1.0 Content-Language: ja Subject: Re: R: Startup/shutdown script X-Accept-Language: ja Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hmmm.. what file exactly are you looking at again? I'm not sure if it suppose to write anything... you should try to do netstat -a | grep $TOMCAT_PORT where TOMCAT_PORT is typically 8080 after the restart and see if its truly alive. sleep for like 3 seconds and then grep for the port. Otherwise, try directly echo'ing out some debug vars and see if that helps. stop') echo "Stopping tomcat" ... whatever ... see if that outputs to your log ----- Original Message ----- From: "Simone Chiaretta" Date: Sunday, February 16, 2003 3:23 pm Subject: R: Startup/shutdown script > Thanx > I've tried everything, but it seems like the script is not > executed when the > server shutdown > > during the startup I see.. > > Starting Tomcat [OK] > > while during the shutdown I see > > Stopping atd [OK] > here should be tomcat > Stopping mysql [OK] > > Very strange to see this. > > Ty > Simone > > > > > -----Messaggio originale----- > > Da: jmong@adobe.com [mailto:jmong@adobe.com] > > Inviato: domenica 16 febbraio 2003 19.22 > > A: Tomcat Users List > > Cc: Tomcat User List > > Oggetto: Re: Startup/shutdown script > > > > > > Instead of > > > > #!/bin/bash > > > > could you try > > > > #!/bin/sh > > > > also you can try to capture the pid during startup and if its still > > alive you can forcefully kill it when you shut it down > > > > ./startup.sh > /dev/null 2>&1 & > > echo $! > $TOMCAT_HOME/logs/tomcat.pid > > > > shutdown.. > > ./shutdown.sh > > if [ $? != 0 ]; > > then > > kill -9 `/bin/cat $TOMCAT_HOME/logs/tomcat.pid` > /dev/null 2>&1 > > fi > > > > also I assume you're running this guy as root... because if > you're not > > then you might have to give the user permissions to read/write into > > the file system where tomcat is installed. > > > > The other suggestion i can offer is rather than cd to the directory, > > specify the full path to the startup/shutdown script > > > > Hopefully that helps. > > > > Jan-Michael > > > > ----- Original Message ----- > > From: "Simone Chiaretta" > > Date: Sunday, February 16, 2003 10:03 am > > Subject: Startup/shutdown script > > > > > Hello All, > > > I'm using tomcat 4.0.4 on a linux (red hat 7.3) server > > > I've a problem shutting down the tomcat deamon when the > machine is > > > stopped/rebooted from maintenance. > > > The problem is that during the shutdown the shutdown script (the > > > script I'm > > > referring to is the one below, not the shutdown.sh inside tomcat > > > bin dir) is > > > not executed (or, at least, it doesn't write to the console > > > "Shutting down > > > tomcat [OK]" nor write it to the boot.log nor messages and also > > > doesn'twrite to the catalina.out file the fact that tomcat was > > > shut down. > > > > > > If I execute the script at cmd line, the script shuts down the > > > process....Does anybody has a clue of what the problem could be? > > > Thank you > > > Simone > > > > > > Addendum: > > > I'm using this script: > > > > > > #!/bin/bash > > > JAVA_HOME=/usr/java/j2sdk1.4.0_01 > > > TOMCAT_HOME=/usr/jakarta-tomcat-4.0.4/ > > > export JAVA_HOME TOMCAT_HOME > > > > > > case "$1" in > > > start) > > > cd $TOMCAT_HOME/bin > > > ./startup.sh > > > ;; > > > stop) > > > cd $TOMCAT_HOME/bin > > > ./shutdown.sh > > > ;; > > > *) > > > echo "usage tomcat start|stop" > > > ;; > > > esac > > > > > > this is named tomcat, set into the init.d dir inside /etc > > > and there is K11tomcat link in the rc0.d dir inside /etc > > > > > > > > > ------------------------- > > > Simone Chiaretta > > > www.piyosailing.com/S > > > Any sufficiently advanced technology is indistinguishable from > magic> > > > > > > > --------------------------------------------------------------- > ---- > > > -- > > > To unsubscribe, e-mail: tomcat-user- unsubscribe@jakarta.apache.org > > > For additional commands, e-mail: tomcat-user- > help@jakarta.apache.org> > > > > > > > > ----------------------------------------------------------------- > ---- > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org > > For additional commands, e-mail: tomcat-user- help@jakarta.apache.org > > > > > > > > > > > ------------------------------------------------------------------- > -- > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-user-help@jakarta.apache.org