tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "andy wix" <stix...@hotmail.com>
Subject Re: Runtime exec (again)
Date Thu, 02 Dec 2004 17:04:25 GMT
Hi,

The shutdown command now works OK.

There have been a few issues with this that I didn't have in the right 
combination.

The Tomcat service must have suitable permissions. To do this:
- Under control panel select Admin tools -> Services
- Right click Apache Tomcat service and select properties
- Select the logon tab
- Under 'This account' select a user account with administrator role.

Not that Windows 2K doesn't come with a shutdown command.  There is one 
supplied with the Win2K resource kit.

- The command must be run from the overloaded exec method that takes a 
String array as it will not work declared as a string.
- Both output and error streams must be read otherwise the process will 
hang.
(see http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html)

- The code will not run from a batch file.

Thanks for your help.

Andy

_________________________________________________________________
Express yourself with cool new emoticons http://www.msn.co.uk/specials/myemo


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message