Automatically reboot OS X 10.7 after kernel panic?
Solution 1:
Open the Energy Saver pane in System Preferences. There's an option to Restart automatically if the computer freezes, if you check that you should get the behaviour you desire.
Note that there are two tabs in Energy Saver—one for when you're on battery and one for when you're running from the power adapter; make sure you set it for each state you want.
Solution 2:
I don't know if something changed on Mountain Lion, but I no longer have the checkbox to restart automatically if the computer freezes.
My MacBook Air restarts automatically a few seconds after this message is shown:
If I'm using it in clamshell mode, I can press any key on an external keyboard to restart immediately.
Solution 3:
The option in energy saver is not there on my Mac Pro machines running Mac OS 10.14.4. Running this as root does the trick:
systemsetup -setrestartfreeze on