GNOME Bugzilla – Bug 613422
Allow configuration of cable disconnect timeout
Last modified: 2013-02-11 19:04:58 UTC
It would be useful if NetworkManager didn't down the network interface as soon as it detects that there is no cable. By all means alert the user as to the fact that the cable has been disconnected, but don't down the interface until the timeout defined by /proc/sys/net/ipv4/tcp_fin_timeout has been reached. If you've got a download going, ssh, IM.. etc etc there is no reason why these need to be shut off if your cable pops out for <tcp_fin_timeout time
It depends; if you're a laptop user who's disconnecting and taking your laptop to a conference room, you don't really want NM to think that you're still using the cable for internet. NM 0.8 currently has a 4-second timer where it will delay taking the device down if the carrier comes back within 4 seconds, but any more than 10 seconds really and the use-cases will really start to conflict like I describe here. We should think about it more and see if there is some way to handle this better though.
Adjusting this bug report. It would be useful to make the timeout configurable. Maybe globally, maybe per interface, I don't know. But some advanced users would like to retain their previous practice of maintaining TCP connections over longer physical disconnects. Of course, if we have a better way, no problem.
We'll actually be work on this more in bug #688284 so duping it there for now. In the future we can potentially revisit configurable timeouts, but perhaps the additional options proposed in bug 688284 will work for now. They will allow you to specify that NM should ignore carrier events if you know that you'll never be moving that workstation. A random follow-on to that would be to renew the DHCP lease if the cable has been disconnected more than 30 seconds, which could indicate a router restart or something liek that. *** This bug has been marked as a duplicate of bug 688284 ***