The “reboot” command is a system administration utility used to restart a computer’s operating system. It is a command-line tool that can be executed from a terminal or console session.
When the “reboot” command is executed, the system will shut down all running processes, terminate all active user sessions, and then perform a system restart. This allows the operating system to reload its components, apply any updates or changes that may have been made, and prepare for a fresh start.
It’s important to note that executing the “reboot” command will result in the immediate termination of all active processes, which can result in data loss or corruption if any unsaved work is present. Therefore, it is recommended to save all open files and close any running applications before issuing the reboot command.
Additionally, the “reboot” command should be used with caution as it can potentially cause system damage or instability if executed improperly or in an inappropriate context. It is generally recommended that only system administrators or those with appropriate privileges should use the “reboot” command.
If you encounter the below error while running the command reboot:
reboot: command not found
you may try installing the below package as per your choice of distribution:
Distribution | Command |
---|---|
Debian | apt-get install sysvinit |
Ubuntu | apt-get install upstart-sysv |
Arch Linux | pacman -S systemd-sysvcompat |
Kali Linux | apt-get install runit-init |
CentOS | yum install usermode |
Fedora | dnf install systemd |
Raspbian | apt-get install upstart |
reboot Command Examples
1. Reboot the system:
# reboot
2. Power off the system (same as `poweroff`):
# reboot --poweroff
3. Halt the system (same as `halt`):
# reboot --halt
4. Reboot immediately without contacting the system manager:
# reboot --force
5. Write the wtmp shutdown entry without rebooting the system:
# reboot --wtmp-only