OpenSSH Escape Sequences (aka Kill Dead SSH Sessions) – The Lone Sysadmin
Posted by jpluimers on 2017/06/16
You can get the below help when pressing these keys in an OpensSSH session:
- Enter
- ~
- ?
So thats Enter, followed by tilde, then question mark.
Then you get this help:
Supported escape sequences: ~. - terminate connection (and any multiplexed sessions) ~B - send a BREAK to the remote system ~C - open a command line ~R - request rekey ~V/v - decrease/increase verbosity (LogLevel) ~^Z - suspend ssh ~# - list forwarded connections ~& - background ssh (when waiting for connections to terminate) ~? - this message ~~ - send the escape character by typing it twice (Note that escapes are only recognized immediately after newline.)
The one I use most is below; it leaves my tmux session alone.
- Enter
- ~
- .
–jeroen
via: SSH Escape Sequences (aka Kill Dead SSH Sessions) – The Lone Sysadmin






Leave a comment