In Windows 2000, you can configure a First failure, Second failure and Subsequent failures action to be performed if the service fails.
To do so:
1. Press Start / Programs / Administrative Tools / Services.
2. Double-click the service you wish to configure.
3. On the Recovery tab, select from:
Take No Action (the default)
Restart the Service
Run a File
Reboot the Computer
If you select Run a File, type one of the following:
forcedos.exe <Drive:>\Folder\batchfile.bat
wscript.exe <Drive:>\Folder\VBscriptfile.vbs
wscript.exe <Drive:>\Folder\JAVAscriptfile.js
Press OK and exit the Services Manager.
NOTE: Monitoring for failures requires minimal overhead as the Event log entries are monitored instead of polling the service status.
NOTE: Netsvc and SC are also included in the
Windows 2000 resource kit.