Has anyone been able to restart a mac from a ssh remote command. Ie from remote machine issue command like this:
ssh user@remotemachine /sbin/restart
I know that I can use ARD for this, but i would like to integrate something like this into the back end of a web page and i need to be able to send a restart command and run a script remotely on the machine... I have experimented with running an osascript command to restart finder, but this will time out if applications are running that require user input to shutdown.
Anybody tried this or have any suggestions??