Create a GPO to schedule restart and check windows services

nav2567
nav2567 used Ask the Experts™
on
Hello,

I need to script and create a GPO to schedule restart of computers in a specific OU on every Sunday@4AM.  Additionally, upon starting up of the computers, I need to check if 2 windows services are up and running.  Start them if they are not running.

Please advise how to do that.

Many thanks...
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
This is for the GPO part:
https://www.petri.com/run-startup-script-batch-file-with-administrative-privileges

And the batch script is just a one liner per service:

sc query AppMgmt | findstr /C:STOPPED && net start AppMgmt

Open in new window


But I don't understand why this is neccessary... a service can be configured to retry failed starts multiple times. See tab "recovery" in the services console.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial