|
|
Question : How to Check if Service is Running on Windows 2000 Server
|
|
I am wondering from the command line or using a batch file (.bat) how can I check if a certain service running or not ?! example: Microsoft Exchange System Attendant
because I want the batch file to Stop the service only if it is running.
Thanks
|
Answer : How to Check if Service is Running on Windows 2000 Server
|
|
sc query | findstr /C:"Microsoft Exchange System Attendant" if errorlevel 1 net stop "Microsoft Exchange System Attendant"
Hope it helps,
Michael
|
|
|
|