Scheduling a Reboot for your Linux Dedicated Server

To install updates for the kernel and increasing the performance of the server, rebooting your dedicated server once during a month is required.

After installing the updates, it is advisable not to reboot your server instantly. If you wish to reboot your server (ie. when the traffic is low on your website), It is always recommended to wait for low usage times.

Assuming that you are having access to the command line, enter the following “at” command as root on your command line interface and hit the “Enter” button of your keyboard:

at 3am sunday

Once you hit the Enter button, the command prompt will open to ask for input. Simply enter “reboot” as shown below:

at> reboot

Lastly, in order to save the settings, press “CTRL+D”.

That’s it ! You server will now reboot at the time you have specified.

It is better to have a server monitoring setup, just in case your dedicated server fails to reboot. If you are having a remote server, it is likely that the clock timezone may differ from your local machine. To make sure about the timings, login into your server via SSH, enter “date” to know the exact time.

The “at” command could be used to schedule any task which you want to run once. In order to know more about the “at” command enter “man at” through your command line interface.