This content originally appeared on David Walsh Blog and was authored by David Walsh
Restarting and shutting down a computer remotely is a frequent task for remote system administrators. As someone that writes many shell scripts, I also find myself automating system restarts. Let’s look at a few ways to restart Mac systems from command line!
Restart a Local Mac
To restart a local Mac system from command line, you can execute:
sudo shutdown -r now
Restart a Remote Mac
To restart a remote Mac system, you can execute:
ssh -l {AdminSystemAddress} sudo shutdown -r now
Restart at a Specific Time
You can specify a restart at a specific time:
# Format: sudo shutdown -r hhmm # Restart at 11:30pm local time sudo shutdown -r 2330
System restarts are good after massive updates or just for clearing out system resources. These command line examples should help restart a Mac locally or remotely.
The post Restart Mac From Command Line appeared first on David Walsh Blog.
This content originally appeared on David Walsh Blog and was authored by David Walsh
David Walsh | Sciencx (2023-05-09T12:35:12+00:00) Restart Mac From Command Line. Retrieved from https://www.scien.cx/2023/05/09/restart-mac-from-command-line/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.