dhcpcd IncompatibilityThe following text is now obsolete as dhcpcd-1.3.22-pl4 contains updates to cope with NTL.
dhcpcd
has a feature and a bug that stops this working optimally.
dhcpcd requests a renewal with a
lease time option set to the value of the lease time it was
initially given - in this case 1hr - so dhcpcd is
locked into a cycle of requesting renewals every half hour.
dhcpcd only calculates T1 and T2
(the times to renew/rebind) if they aren't in the message or
haven't been calculated from the lease time already. So the new
lease time is effectively ignored and only the values of
T1/T2 based on the initial lease time are
used.
dhcpcd as delivered will work[1], but when connecting to
an NTL dhcp server running the new strategy:
dhcpIPaddrLeaseTime option from the request in
buildmsg.c/buildDhcpRenew
DhcpOptions.val[dhcpT1value] and DhcpOptions.val[dhcpT2value]
to zero at the start of client.c/parseDhcpMsgRecv (if they already
exist)
With these changes, on an NTL network, the lease time starts at 1hr and
is gradually stepped up to 24hrs on subsequent renewal requests as
expected. This should be long enough for a system that is shut down
overnight to still retain the original IP address (assuming it is not
released with the -k option). In this case the initial lease time will remain at 24hrs.
This is not a complete solution since the info/cache file is not updated when the lease time changes. It is not clear what the strategy on this should be - it seems odd that the lease times are held in the cache, rather than simply being logged. This is a problem that is more properly addressed by the code author if and when a fix to the above glitch is incorporated
dhcpcd-1.3.22-pl3.tar.gz
and dhcpcd-1.3.22-pl3-ntl.diff
into a work area.
tar xzf dhcpcd-1.3.22-pl3.tar.gz cd dhcpcd-1.3.22-pl3 patch -p1 < ../dhcpcd-1.3.22-pl3-ntl.diff
# Check configure options with './configure --help ./configure make # May need to be root for next line make install
-H option cannot be used.
| Original at http://www.sharpe-practice.co.uk/isharpe/technote/ntldhcpcd.htm. | $Id: ntldhcpcd.htm,v 1.5 2003/02/03 13:50:12 isharpe Exp $ |