From tomcat-user-return-126453-apmail-jakarta-tomcat-user-archive=jakarta.apache.org@jakarta.apache.org Wed May 11 08:38:28 2005 Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@www.apache.org Received: (qmail 63249 invoked from network); 11 May 2005 08:38:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 11 May 2005 08:38:28 -0000 Received: (qmail 51950 invoked by uid 500); 11 May 2005 08:41:13 -0000 Delivered-To: apmail-jakarta-tomcat-user-archive@jakarta.apache.org Received: (qmail 51927 invoked by uid 500); 11 May 2005 08:41:12 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: 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 51908 invoked by uid 99); 11 May 2005 08:41:12 -0000 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=HTML_30_40,HTML_MESSAGE,HTML_TEXT_AFTER_BODY X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from rsys001x.roke.co.uk (HELO rsys001x.roke.co.uk) (193.118.201.108) by apache.org (qpsmtpd/0.28) with ESMTP; Wed, 11 May 2005 01:41:12 -0700 Received: from rsys005a.comm.ad.roke.co.uk ([193.118.193.85]) by rsys001x.roke.co.uk (8.12.8/8.12.8) with ESMTP id j4B8bNqP011908 for ; Wed, 11 May 2005 09:37:23 +0100 Received: from [193.118.194.24] (stove2.comm.ad.roke.co.uk [193.118.194.24]) by rsys002a.roke.co.uk with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2657.72) id JF3JXFDD; Wed, 11 May 2005 09:38:16 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C55604.C67F0C00" X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message Subject: Re: tomcat restart? Date: Wed, 11 May 2005 09:37:22 +0100 Message-ID: <4281C442.2040003@roke.co.uk> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: tomcat restart? Thread-Index: AcVWBMb7oh3biwBAThC5FszOMAXP5g== From: "Beton, Richard" To: "Tomcat Users List" X-MailScanner-rsys001x: Found to be clean X-MailScanner-rsys001x-SpamCheck: X-MailScanner-From: richard.beton@roke.co.uk X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N ------_=_NextPart_001_01C55604.C67F0C00 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Patrick Thomas wrote:=0D >Actually, I believe it might be possible. Ugly, but possible. Using=0D >Runtime.getRuntime() to get the current runtime, you can then actually=0D >make a call to a shell command. You could call a batch file that would=0D >shut down the server and then restart it. What I don't know is if the=0D >newly exec'd process gets taken down with tomcat... if so, you could=0D >have the shell program that you call start a new process that would=0D >not be associated with the existing one (in windows you can use the=0D >command 'start' in a batch file to start a separate process... someone=0D >else will no doubt supply the *nix equivalent).=0D > =0D >=0D Thanks for the help. I'm running Tomcat as an init.d System V service =0D on Linux. This means I can't write a simple script to restart it - the =0D restart has to be done as root (although Tomcat runs as a user called =0D tomcat). My startup script already does the work of moving jarfiles and=20 our native library to their correct locations.=0D So I've decided that automatic restart is in the 'too hard' category: =0D instead I'll include in the webapp the means for an administrator to =0D determine whether the deployment is up to date (fresh jarfiles in the =0D shared/lib folder etc). It'll then be a manual administration task to =0D restart Tomcat when required. It won't happen often.=0D Rick=0D --=20 Visit our website at www.roke.co.uk Roke Manor Research Ltd, Roke Manor, Romsey, Hampshire SO51 0ZN, UK. The information contained in this e-mail and any attachments is proprietary= to Roke Manor Research Ltd and must not be passed to any third party without permission. This communication is for information only and shall not create= or change any contractual relationship. ------_=_NextPart_001_01C55604.C67F0C00--