Safely halts or reboots the system.