In our instance we copied the batch file to a utility folder on each server then we'd create the scheduled task. I'm guessing with this method that you can export the scheduled task and then import it to other servers without having to copy any thing else.
I like it. Thank you. Thanks Scott. Simple and works great. The only person that can directly logon the server in our case is the Admin so they are the only one that can access the registry so I don't see where the security issue is that was mentioned earlier. Learn Windows Windows Server. Schedule Windows Server to reboot. General Windows Windows Server. Scott D. Last Updated: Jan 17, 1 Minute Read. Reply Facebook Twitter Reddit LinkedIn. Scott Danton. Main Areas of Contribution:.
Track Progress. Earn Credits. Step 2: Create a new task. Step 3: Follow the Scheduled Task Wizard. Step 4: Select the program to run. Step 5: Select the Frequency. Step 6: Select the time and day you want the task to start. This can be once a week at 3 AM or every Wednesady and Friday nights. Step 7: Enter the username and password for a user. Step 8: You have successfuly scheduled the following task. Step 9: Advanced Options.
Jackson Mar 23, at pm. Steve Mar 30, at am. Or you could type something like the following at the command prompt. You can check for tasks quickly by typing "at" in the cmd prompt. Bruce Mar 2, at am. RumRaisin Sep 9, at pm. PolarPeter Dec 4, at pm. Never mind. Instead you should check out the schtasks. There can be many reasons why you will need to schedule a restart of a server instead of just rebooting it right away.
Most of the time it is because it is being used and you have to wait for a maintenance windows to perform the task. Often I have needed to schedule a server reboot or a Windows Service restart and I have been using the good old AT command for this task in many years. The new command to do those kind of tasks now, is the schtasks.
If you try to run the AT command on a newer operating systems, you will get the message below:. To schedule a server restart you should run the following command line:. If you prefer to use the graphic user interface to check up on your newly created task or to change the time it will run, you can use the Windows Task scheduler.
You can of cause also remove a task with schtasks, like in the example below:. The smart thing about scripting this command instead of using the Task scheduler GUI is that you can run other command line tools first and then finish with a server reboot then the task is done, but you can of cause also use the Task Scheduler GUI if you are more comfortable using that. I hope you found what you were looking for in this post. If you have any questions, please drop me a comment below.
I often use software instead of command line instructions for my routine task. Probably, the command line prompt is not my cup of tea. There is a lot of GUI you can use instead if that is easier for you.
I do love performing such tasks from the command line myself. Now generally, I am quite inactive in using the CMD Comand Prompt because as I have seen that it involves quite a complications but with your given guide I was able to follow it thoroughly … to schedule reboot my Windows server.
Notify me of followup comments via e-mail.
0コメント