Re: dhcpcd timeout



On 06/11/2010 04:49 AM, Victor Gaydov wrote:
> The problem was related to timeouts: 45s is not enough. I changed
> DHCP_TIMEOUT in sources and added '-t' option to dhcpcd and everything
> works fine. Is it a way to change dhcp timeout in config file?


There is not, I'm afraid. N-M ignores the timeout mechanisms in the DHCP
clients, choosing instead to implement it's own timeout that can be
changed only by editing the sources (as you already have done).

You are not the first person to have problems with this; a few months
ago this made it difficult for me to use N-M with a network that had
snail-like (but still usable) DHCP servers.


The issue of DHCP timeouts is actually something I looked into a few
months back:
http://mail.gnome.org/archives/networkmanager-list/2010-January/msg00051.html

I didn't have time to follow up on it, though, and in any case the itch
went away when my IT department fixed their DHCP servers. :)

I'm (still) of the opinion that the best way is to let the DHCP client
daemons handle the timeouts and remove the timeout logic from N-M. The
DHCP clients seem better suited for this task than N-M is, esp. since
they can adjust their behavior depending on the details of the DHCP
transaction. DHCP their job, after all, and they know better than
anything else when DHCP is hopeless. dhclient certainly provides a means
of setting the timeout in config files, and on Debian at least, I think
dhcpcd does as well.

The other proposal is to have N-M's internal timeout be configurable,
and/or have N-M be smart enough to extend its internal timeout when DHCP
servers exist but are slow. I'm not yet convinced that this is the right
way though; it seems better to have N-M know as little as possible about
the DHCP transaction and let the DHCP clients handle as much as possible.

Let the DHCP client be the DHCP client. That's the "Unix way" I'd say :)

HTH!

Have a good one,
Daniel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]