![]() |
2010-01-11
, 16:12
|
Posts: 515 |
Thanked: 193 times |
Joined on Oct 2009
|
#32
|
![]() |
2010-04-11
, 13:47
|
|
Posts: 64 |
Thanked: 20 times |
Joined on Dec 2009
@ Adelaide, Australia
|
#33
|
![]() |
2010-04-11
, 14:21
|
Posts: 20 |
Thanked: 26 times |
Joined on Jan 2010
|
#34
|
![]() |
2010-04-11
, 20:55
|
|
Posts: 1,559 |
Thanked: 1,786 times |
Joined on Oct 2009
@ Boston
|
#35
|
They doesn't work as well as protocols which detect a failed connection and restart, like IM protocols, but they do work.
I use a VPN to reach my server from my laptop for this reason - so that I can continue with SSH connections after the IP connection has broken and restarted with a different IP when tethering through a phone.
But I found that it can take an annoyingly long time after the connection is restarted before the SSH will resume. This is not due to SSH, but due to TCP sometimes not responding quickly to a resumed underlying connection, once it's got into slow retransmit mode. Once it has recovered, it's fast again.
Now I use GNU Screen on the server and that's much better
The key words are "in flight". Take a peek at this netcat trace:
The ethernet cable was removed from the laptop after opening the connection, and before typing "x" and therefore before the write() call. There is no significance to the fact it's using an SSH port, because what happens remotely is irrelevant once the cable is removed
TCP tried to transmit the packet containing "x" for about 15 minutes, before giving up and reporting ETIMEDOUT.
It took about 15 minutes - I'd mistaken the 120 seconds for something else. Oops
If you don't have data in flight, and no keepalives or applications timeouts, this doesn't happen - you can indeed resume any amount of time later. That's a basic property of TCP/IP.
But most application protocols do, of course, transmit something from time to time - otherwise they wouldn't be able to tell the difference between a temporarily lost link and one which is permanently gone, to be cleaned up.