Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

My MacBook Air froze all of a sudden: the keyboard, trackpad and display are all unresponsive. However, ssh works.

I have one tcsh session active. Which signal do I send to tcsh for it to gracefully quit, saving history prior to quitting?

My tcsh does have all appropriate savehist already setup, i.e. if I were to type in exit, all history would be saved. Perhaps there is even some way for a superuser to steal the terminal, and actually pass in the characters exit\n as if they were typed in on the virtual terminal by the logged-in user?

share|improve this question

1 Answer 1

I tried doing sudo shutdown -r +1, then exit, through tcsh on ssh, and it seems to have worked. The system didn't reboot (probably because it was already frozen) and continued responding for ping6 as if it was still online, but ssh did stop working, and it would seem like tcsh within Terminal was quit out nicely, too.

After waiting for the userland shutdown to complete, I had to press and hold the power button for 5 seconds to actually reboot.

I'm not sure if the same result would have been achieved had I have skipped shutdown(8).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.