Skip to content
Log In Sign Up [email protected]

Reboot Now

sudo reboot

On current distributions this is the same as sudo systemctl reboot. Services are stopped in order, filesystems are synced, and the machine restarts. Your SSH session closes; wait a minute, then connect again.

Reboot at a Set Time

The shutdown command can wait, warn logged-in users, and be canceled:

CommandWhat it does
sudo shutdown -r nowReboots immediately.
sudo shutdown -r +10Reboots in 10 minutes.
sudo shutdown -r 03:30Reboots at 03:30 server time.
sudo shutdown -r +10 "Kernel update, back in 5 minutes"Adds a message for logged-in users.
sudo shutdown -cCancels a scheduled reboot.

Check the server's clock with date before you schedule by time; it may be in another time zone than you are.

Does the Server Need a Reboot?

On Ubuntu and Debian, a file appears when an installed update needs one:

cat /var/run/reboot-required

On AlmaLinux and Rocky Linux:

sudo needs-restarting -r

The command is part of the dnf-utils package. Often only one service has to be restarted, not the whole server: sudo systemctl restart nginx is enough after changing the web server's configuration.

Before You Reboot

  • Who is logged in: who lists other sessions.
  • What is running: wait for backups, imports, and package upgrades to finish.
  • What starts on boot: systemctl is-enabled nginx should answer "enabled" for every service you need. A service started by hand will not come back by itself.
  • Recent configuration changes: test them first. For example, sudo sshd -t checks the SSH configuration, and sudo nginx -t checks the web server's.
  • Disk mounts: a wrong line in /etc/fstab can stop the boot. sudo mount -a reports errors without rebooting.

After the Reboot

uptime
systemctl --failed
uname -r

uptime confirms the restart, systemctl --failed lists services that did not start, and uname -r shows the running kernel. Then open your site or application and check it as a visitor would.

If the Server Does Not Come Back

Give it a few minutes: a filesystem check after an unclean shutdown can take time. If SSH still does not answer, open the server's console in your provider's control panel. The console shows the boot messages and lets you log in without the network, which is usually enough to find a failed mount or a misconfigured network interface.

Reboot, Shutdown, and Hard Reset

  • Reboot: stops everything cleanly and starts again.
  • Shutdown (sudo shutdown -h now): stops the server and leaves it off; you start it again from the control panel.
  • Hard reset from the control panel: the same as pulling the power. Use it only when the server no longer responds, because unsaved data can be lost.

Updated:

Linux VPS with Full Root Access

MUVCloud cloud servers run on KVM with Enterprise NVMe SSD storage and full root access, in Turkey, the Netherlands, and the USA.

Cloud VPS Plans Starting at2.99 $/mo Cheap Linux VPS

No Limits on Service or Support

You are not on your own as your projects grow. Our support engineers are ready 24/7, on several channels, whenever you need them.

Support specialist
  • 100% customer satisfaction goal
  • Our own hardware
  • 24/7 ticket and email support
  • 4 countries with locations