Shutdown, Restart And Sleep From Terminal 0


Shutdown, Restart And Sleep From Terminal


Terminal is a powerful piece of software. Today we are going to explore the command line options for shutting down, restarting and sleeping your Mac from the command line. These tools are very useful if you are writing scripts, or just want a different way to shutdown your Mac. All of these tips use Terminal which is located in the Applications > Utilities folder. You can’t do any damage to your Mac, however you will need your admin password for the commands to work.

To shutdown, type the following command:

sudo shutdown -h now

On enter it will begin the shutdown process. It is a rather severe shutdown process. It will not tell you to save documents if they are open. You can replace the word ‘now’ with a time in the 24 hour format.

To restart use the following command:

sudo shutdown -r now

To put your Mac to sleep use the following:

sudo shutdown -s now

The shutdown command is very versatile. There are other Mac Terminal commands which can reboot and sleep you Mac, however I prefer the shutdown command as it is easy to remember.

If you want to keep up with the latests post from Mac Tricks And Tips I recommend you subscribe to the RSS Feed.

Where To Next?

  • Subscribe To Mac Tricks And Tips