I am using Windows 7 and with Debian running as a VM (VMware Player). My window manager is Gnome. I mostly open a lot of terminal windows in my VM and arrange them over my desktop. With these terminals I connect to remote servers via ssh.

Going back to the VM after putting my host OS to sleep and waking it up, all terminals that were connected through ssh "hang", not accepting any new input, even after resetting them. This is very annoying, because I have to close and reopen them every day. I am aware that the ssh session is closed in the process of turning of my host OS, but I would like to know if there is a way to reset the terminals in a way, so that I can keep my prior window arrangement with fresh terminals.


Use Enter ~ . to exit a frozen SSH connection, then just start a new one in its place.

Alternatively, run pkill ssh from a new terminal, to kill all SSH connections.

Better yet, try mosh, which is designed to remain connected even after connection loss or even network reconfiguration.

(The Reset menu item is not going to work, because it only resets the terminal window's state [similar to turning a monitor off and on again], but it does not know anything about what is actually running in that terminal window.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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