Restart Windows Service Using Commands

WindowsA client has recently been having an issue with a process which appears to starts having problems after it has been running for a few days. While the application was investigated, they wanted to restart the service periodically restarted automatically.

The below Windows command script was created to stop the named service, wait 30 seconds and then start the service again:

@echo off

net stop {service name}

timeout 30

net start {service name}

exit

Change the highlighted section to the name of the service to be stopped and started.

What should we write about next?

If there is a topic which fits the typical ones of this site, which you would like to see me write about, please use the form, below, to submit your idea.

Your Name

Your Email

Suggested Topic

Suggestion Details

Leave a Reply

Your email address will not be published. Required fields are marked *