The "net start <service name>" and "net stop <service name>" commands will allow you to stop and start Windows services from the command line (and thus from a batch script). You can get the service name from the "Services" property window.
On Wed, 2005-10-12 at 06:18, Tom Burke wrote: > I'm running Tomcat 5.0.28 on a Windows 2003 server, and I need to > automatically shut it down & restart it. One way is to control it via > shutdown.bat & startup.bat, and run these as scheduled tasks at (say) > 3:30am and 3:31am. However, I've noticed that while shutdown.bat will > shut it down if it was previously started as a service, startup.bat > won't run it as a service, it starts it at a command prompt. > > My question is: does this matter? If I'm running on Windows are there > any advantages to running Tomcat as a service? Or disadvantages to > running from the command prompt? The server is dedicated to tomcat, by > the way. > > Tom Burke > > > --------------------------------------------------------------------- > 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]