News for hackers. Stuff that matters.
Re:Run last command as root by delano on Thursday December 16, 2010 @12:15PM (#2012748)
The biggest shell-related revelation for me recently was that ~ is a special character in SSH. If you have an SSH session that's hanging and ctrl-C / ctrl-D isn't responding, try typing "~." (without the quotes).

  man ssh | grep -A 30 tilde
Re:Run last command as root by pyre on Thursday December 16, 2010 @12:27PM (#2012803)
The ~ needs to follow a newline. So I usually make sure to hit <Enter> explicitly before hitting "~." so that I don't have to repeat the sequence if it doesn't work. It would still work without hitting <Enter> explicitly if the last thing that you typed to the console was <Enter> though.
Re:Run last command as root by jodrellblank on Thursday December 16, 2010 @03:06PM (#2013406)
If you have an SSH session that's hanging

It's usually because I've accidentally fumbled ctrl-s which means 'play dead'. Why that's important enough to take a two-key home row shortcut, I don't know. The cure is to press ctrl-q. Same wonder about the cure.

Re:Run last command as root by drewp on Friday December 24, 2010 @01:04AM (#2036682)
I can't argue for it taking such a prime spot on the keyboard, but I used c-s/c-q every day to freeze scrolling output that I want to look at. Your terminal scrollback will still work during the pause.