dhcpcd-discuss

Re: Debugging prefix delegation: dhcpcd suddenly fails obtaining a prefix (but other devices/clients work)

Roy Marples

Mon Mar 08 10:04:50 2021

Hi Timo

On 07/03/2021 00:45, Timo Sigurdsson wrote:
I've been using dhcpcd on my Debian based router for a couple of years now and it has worked well until last month. From one day to another, dhcpcd fails to obtain a new prefix despite the fact that the configuration or setup haven't changed. I did quite some digging and testing which lead me to believe that my ISP made some changes to its DHCPv6 server which makes it ignore dhcpcd's ia_pd requests. I can't merely blame it on my ISP, though, because if I use a different DHCPv6 client (wide-dhcpv6-client) on the same machine, I do get a prefix. In other words, I believe the server doesn't like something about the request sent by dhcpcd.

Some background information on my setup:
My connection is a VDSL or PPPoE connection. I get a /56 prefix for my internal clients via IA_PD and the host itself get's a /64 prefix via SLAAC. Both is handled by dhcpcd (7.1.0) on a Debian 10 machine, and they are changed/renumbered daily. The SLAAC part, btw., is still working and the IPv6 connectivity of the router itself is fine. It's only dhcpcd's IA_PD request that goes unanswered, so the internal clients don't get IPv6 addresses anymore. I'll add my dhcpcd.conf at the end. It has worked in this way for about 18 months.

So, here's what I did and tried so far to come to this conclusion:
1) After noticing that I don't get a prefix anymore, I first checked whether there were any configuration changes or updates around the time since the prefix delegation stopped working. I couldn't identify any changes that could have caused this. The machine was already up for a week at that time without changes (meaning it did successfully obtain a prefix 7 times after boot) and the only package update happened a day after prefix delegation stopped working. Nevertheless, just to be safe, I recovered a backup the entire root filesystem of the router that was taken two weeks before the failure and even with that, I cannot get a prefix anymore.

2) I tested prefix delegation with the ISP supplied router (an AVM Fritz!Box) and with that everything works as expected. I even hooked up a different VDSL modem to my Debian router, but that didn't help (well, I wasn't really expecting it to).

3) I checked my firewall setup and enabled verbose/detailed logging, but nothing related to DHCPv6 or ICMPv6 gets filtered. With tcpdump I can see that the IA_PD request is sent repeatedly, but there is simply no reply by the server.

4) Eventually I tried a different DHCPv6 client, namely wide-dhcpv6-client, and with that I can obtain a prefix.

5) I looked at the requests sent by dhcpcd and wide-dhcpv6-client with tcpdump to see if I can spot any differences:
- wide-dhcpv6's clientid looks different (its form) than dhcpcd's. So I disabled the duid option in dhcpcd.conf and enabled clientid. Then their form looks the same, but that didn't solve the problem.
- dhcpcd sends a vendor class option while wide-dhcpv6 doesn't. I couldn't find a way to disable sending this. I tried setting a different vendclass (I took the enterprise number of my ISP supplied device) but that didn't help either (and I also didnt really know what to put in the data field...).
- dhcpcd sends options 82 and 83 that wide-dhcpv6 doesn't send. And it also has 'reconfigure accept' which wide-dhcpv6 doesn't.
 From the dumps the missing vendor class option with wide-dhcpv6 looked like the most meaningful, but as I said, I don't know how to disable sending it.

6) I also tried some other dhcpcd.conf changes to see if they help (such as removing the rapid commit option), but no luck. I also enabled debug logging, but thtat's didn't show anything useful either.


Do you have any ideas what might cause this issue? Or how I could better debug this? I have packet captures of both dhcpcd's DHCPv6 initialization as well as wide-dhcpv6-client's successful prefix delegation. If you'd like to look at them, please contact me as I don't really whether they contain any sensitive information.

You can try disabling options one at a time like so:

# Don't send vendor class
nooption dhcp6_vivco
# Don't allow timer overrides
nooption dhcp6_sol_max_rt, dhcp6_inf_max_rt
# Don't allow reconfigure
nooption dhcp6_reconfigure_accept

Find the option that's causing the problem and then complain to your ISP as dhcpcd is to the best of my knowledge enitrely RFC compliant here.

Roy

Follow-Ups:
Re: Debugging prefix delegation: dhcpcd suddenly fails obtaining a prefix (but other devices/clients work)Timo Sigurdsson
References:
Debugging prefix delegation: dhcpcd suddenly fails obtaining a prefix (but other devices/clients work)Timo Sigurdsson
Archive administrator: postmaster@marples.name