How do I reboot a Solaris UNIX machine or server using the command / shell prompt? Is it possible to reboot the server using the ssh command?
The Solaris Unix machine must be rebooted for kernel updates and other reasons. This page explains how to reboot a Solaris Unix system using the command-line option.
Tutorial details
Difficulty level Easy
Root privileges Yes
Requirements Solaris Unix
Est. reading time 2 minutes
Rebooting a Solaris Unix systemYou can use any one of the following commands. The procedure is as follows:
- First, login as the root user:
Quote su -
- For remote Unix server use the ssh command and then use the sudo/su:
Quote ssh user@solaris-server-ip-here
- Once logged in as the root user type the reboot command:
Quote reboot
- One can reboot the box using the init command, run:
Quote init 6[/list]
(https://pix.cobrasoft.org/images/2023/01/11/How-To-Reboot-a-Solaris-UNIX-System-Using-CLI.webp)
How to reboot a system by using the shutdown commandYou can use schedule reboot with the shutdown command. The following will reboot Solaris box in 180 seconds with a message:
Quoteshutdown -y -i6 -g 180 " ==== Rebooting for kernel and apps upgrades ====="
You can also reboot using a specific disk and/or kernel. The following example reboots using a specific disk called disk2 and kernel:
Quotereboot "disk2 kernel.build-k2/unix"
Summing upYou can use any one of the following command to reboot your Solaris Unix system:
- reboot command
- init command
- shutdown command
See the following man pages using the man command:
Quoteman reboot
man init
man shutdown