Re: Why does ssh keep hanging



unruh <unruh@xxxxxxxxxx> wrote:
I am connecting to the net via a home router wireless (Zoom) and I am
discovering that if I leave an ssh session for more than a minute of
two, it freezes (ie the ssh session stops being connected and the screen
is frozen)

One (or more) of the firewall devices between you and the remote server
is timing out your session. To stop this happening you need to use the
ServerAliveInterval setting.

For example, drop this in your ~/.ssh/config, or if the file already
exists, tweak it appropriately:

Host *
ServerAliveInterval 60

I often have these two configuration items in there, too, but YMMV:
ForwardX11 yes
Compression yes

Chris
.