Restarting or Shutting Down a

4

Computer

In this chapter you will find commands you can use to shut down or restart a local or remote computer.

Computers often must be shut down or restarted, whether locally or remotely, when installing new tools or making computer repairs. This chapter covers the commands needed to shut down or restart a local or remote computer.

Restarting a Computer

You can use the reboot or shutdown -rcommand to restart a computer at a specific time. See the relevant man pages for more information.

To restart the local computer:

$ shutdown -r now

To restart a remote computer immediately:

$ ssh -l root computer shutdown -r now

To restart a remote computer at a specific time:

$ ssh -l root computer shutdown -r hhmm

Parameter

Description

computer

The IP address or DNS name of the computer.

 

 

hhmm

The hour and minute when the computer restarts.

 

 

Automatic Restart

You can also use the systemsetup tool to set up the computer to start automatically after a power failure or system freeze. See “Viewing or Changing Automatic Restart Settings” on page 59.

53

Page 53
Image 53
Apple Mac OS X Server manual Restarting a Computer, Automatic Restart, To restart the local computer