I'm looking for a script that will kill all the processes on my Mac. To be more specific, the script should kill all the processes and shut down.
Well the point is that I want to kill all the procesess and restart Mac OS X but not shutting it down. I know that there exist commands like sudo shutdown -r now
but it's not working on my Mac (that command is restarting it, but does not kill the processes after rebooting).
I can't use sudo shutdown - h now
because I haven't got access to my Mac (only TeamViewer to connect to my Mac Mini). So I can't push the button on/off/restart.
Any ideas how to do it?
sudo shutdown -r now
does not kill the processes AFTER rebooting. Well, no. If you kill all the processes, that'll include the init process which will once again halt your system. Rebooting will necessarily restart a number of processes.