Skip to content

AutoRestart command

Robomikel edited this page Feb 20, 2021 · 5 revisions

The install-restart command ./ssm install-restart <ServerFolder> will create a scheduled task that will restart the server at a specific time. You will have the option to run in foreground and in the background, similar to the monitor command.

Run Task Whether the user is logged on or not?
Default is N for foreground

This will create a restart task at 6:00 AM system time.
Input AutoRestart Time. ie 3am: 6am

Selecting the Default N. Will run task in the foreground. This means you will see a PowerShell window pop open every 5 minutes and will not run if you log out or not logged in.

Selecting Y. Will prompt for a Username and Password for the user that is currently logged in. It will run the task in the background and you will not see the window pop open. It will also run the server in the background as well. Recommend creating a normal user account to run SSM

User account will need to be in "log on as batch job" group