How-To Geek

Shut Down or Reboot a Solaris System

Solaris is usually used as a server operating system. Because of this, you want to make sure that you shut the system down as gracefully as possible to ensure there isn’t any data loss.

For every application that is installed on your server, you should make sure that you have the correct scripts in /etc/rc(x).d to gracefully shut down the service.

You have more than one command option that you can use. The best command is this, executed as root:

shutdown -y -i5 -g0

This will immediately shut the system down. You can also use the older command that still works:

sync;sync;init 5

You can even use:


If you are trying to reboot the system as opposed to turning it off, you could use:

shutdown -y -i6 -g0


sync;sync;init 6

Or even:


So many commands to do the same thing… almost seems silly.

Lowell Heddings, better known online as the How-To Geek, spends all his free time bringing you fresh geekery on a daily basis. You can follow him on if you'd like.

  • Published 12/13/06

Comments (14)

  1. Steve

    There are differences between shutdown, reboot, init 6.

    Shutdown will issue a warning, and can be deferred.

    init 6 calls application shutdown scripts. reboot does not.

  2. The Geek

    Thanks for the tip… I had read somewhere that reboot calls the shutdown scripts, but I guess that was incorrect.

  3. Ally

    Does any one know how to get the shutdown/hibernate options to appear on the logoff screen for my version: developers solaris 10?
    I just want to use it on my home PC as a desktop OS.

  4. Colin

    The sync’s you’ve added before init are totally superflous.
    “poweroff” only exists on the big SunFire systems.

  5. olivier d

    avoir poweroff and reboot : as they don’t call the /etc/…. scripts they should be avoided unless absolutely necessary.

    prefer “init _number_” (works on old and new versions) for solaris.

    (note: on linux, prefer “telinit _number_” to go in that mode (ex: telinit 1 to go into single user mode)

  6. Ihatebloatware

    Solaris 10 Developers edition – the CME desktop (the old one that looks a bit like an Amstrad 286 GUI, lol) doesn’t seem to have a button to shutdown.

    The KDE desktop – I think I used the command line (terminal, konsole) and just typed in ‘shutdown’ – it’s a bit temperamental cause the default install configures things like DHCP and expects the machine to be online all the time; mine isn’t, so sometimes it refuses to entirely close. Sometimes it doesn’t want to start either but it’s usually ok and hasn’t ever crashed. I haven’t looked at what I should disable / enable yet on the running services…

    nb – Sun’s manual and help pages for commands for mounting USB harddrives are wrong for Developer 10!

  7. Christian O

    How do you create a shutdown script that would reboot the computer for every 30 minutes with the warning script?

  8. ayam


    echo “please reboot this computer NOW”

    put that script in crontab and configure so it runs every 30 minutes

  9. ranga

    i have a question ..

    #shutdown -y -i5 -g0

    here g means gracefully and i means init 5 to shutdown

    what is -y ? what it indicates?

  10. JoeSchmoe

    the ‘-y’ means ‘yes, i really mean to do this’

  11. JoeBlow

    The -g is grace period


    -y is stands for the yes

    so i f we didi not put – y in command the it will ask for

    do you want ot countinue ? (y /n)

    the -y option will automatically responds that question to yes.

  13. some arch user

    This and the comments may be the worst *nix documentation of all time, excluding the Ubuntu forums.

  14. some unix user

    And your comment is helpful like Ubuntu forums right??? I lol’ed

More Articles You Might Like

Enter Your Email Here to Get Access for Free:

Go check your email!