[NTISP] Re: NTISP Digest

Gary Kliethermes ( gary@thewebdepot.com )
Sun, 07 Mar 1999 00:17:26 -0600

I have one program (a web stats generator) that runs as a service that doesn't
always die, but just hangs or stops responding. When you look at the service
in control panel | services, it says it's running so this wouldn't work for me.

Here's what I use. I make a simple batch file like:
net stop service1
net start service1

Then use the schedule service to run it as needed. Since I generate all stats
late at night, I just run it 5 minutes before the stats program is scheduled to
start.

Gary

Danny Sinang wrote:
>
> i have a service running on my nt4 server that keeps on dying because of
> some weird application error.
>
> so i plan to write a script to check every 30 minutes if the service is
> running and it isn't, then restart it.
>
> can anyone tell me what script commands will enable me to do these ?
You can get slepp.exe from our FTP site and use a script like this:
:top
net start service1
net start service2
sleep 600
goto top
then you can run the script with srvany or just in the foreground. If
the
service is running, the "net start" will just return that (otherwise it
will
start the sevice).

-- Dale E. Reed Jr. Emerald and RadiusNT __________________________________________ IEA Software, Inc. www.iea-software.com

The Web Depot, Inc. "Making the Web Work for You" http://www.thewebdepot.com

For more information about this list, including removal,see this url: http://www.iea-software.com/maillist.html