Live data from Hacker News

SSH Multiplexing & other OpenSSH Tricks

symkat.com

1–10 of 24 posts

Re: SSH Multiplexing & other OpenSSH Tricks

#2
+1 just for the multiplex magic, But then, I /would/ say that =)

That TTL thing is handy too, I'm sure I had some understanding of it previously, but reading the article made me check my settings and made me realize my timeouts were ridiculously low so even short disconnections killed my session.

Re: SSH Multiplexing & other OpenSSH Tricks

#3
I do wish keepalive could be turned on/off more dynamically - most of the locations I connect from it's a disadvantage so I don't have it configured, and having to edit the config file when I'm in one where it's useful just annoys me.

I suppose I should just write a script that perl -pi -e 's/KeepAlive yes/KeepAlive no/' .ssh/config or similar, but it still seems ... annoying.

Re: SSH Multiplexing & other OpenSSH Tricks

#5
post #3

I do wish keepalive could be turned on/off more dynamically - most of the locations I connect from it's a disadvantage so I don't have it configured, and having to edit the config file when I'm in one where it's useful just annoys me. I suppose I should just write a script that perl -pi -e 's/KeepAlive yes/KeepAlive no/' .ssh/config or similar, but it still seems ... annoying.

You might be able to provide it with the -o option:

ssh -o "KeepAlive no" example.com

Re: SSH Multiplexing & other OpenSSH Tricks

#6
post #3

I do wish keepalive could be turned on/off more dynamically - most of the locations I connect from it's a disadvantage so I don't have it configured, and having to edit the config file when I'm in one where it's useful just annoys me. I suppose I should just write a script that perl -pi -e 's/KeepAlive yes/KeepAlive no/' .ssh/config or similar, but it still seems ... annoying.

What about in your config file:

  Host *.whatever.com
  ServerAliveInterval 900
  Host *.whatsup.com
  ServerAliveInterval 60

Re: SSH Multiplexing & other OpenSSH Tricks

#9
post #3

I do wish keepalive could be turned on/off more dynamically - most of the locations I connect from it's a disadvantage so I don't have it configured, and having to edit the config file when I'm in one where it's useful just annoys me. I suppose I should just write a script that perl -pi -e 's/KeepAlive yes/KeepAlive no/' .ssh/config or similar, but it still seems ... annoying.

> I do wish keepalive could be turned on/off more dynamically

PuTTY can do that. It's GUI though.

Post reply on HN