dhclient in 'stateless' mode does not wait for ipv6 dad
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
isc-dhcp (Ubuntu) |
New
|
Medium
|
Dan Streetman | ||
Trusty |
New
|
Medium
|
Dan Streetman | ||
Xenial |
New
|
Medium
|
Dan Streetman | ||
Artful |
New
|
Medium
|
Dan Streetman | ||
Bionic |
New
|
Medium
|
Dan Streetman |
Bug Description
[impact]
when configuring an interface in ifupdown to use 'inet6 auto' (SLAAC), the option 'dhcp 1' can also be used, which will use isc-dhcp-client to perform 'stateless' dhcpv6, which does not get a dhcpv6 address, only config info, like DNS domain and server, etc.
bug 1633479 fixed isc-dhcp-client to properly bring up and wait for the interface's ipv6 Duplicate Address Detection (DAD) to complete, which is required for isc-dhcp-client to be able to open a socket and begin broadcasting DHCPv6 requests. However, that fix is skipped when isc-dhcp-client is used in 'stateless' mode, so it fails in exactly the same way, for the same reason; isc-dhcp-client needs to be updated to perform the 'PREINIT6' call to the dhclient script, which properly sets up the interface for dhclient to use.
Without that setup, isc-dhcp-client in DHCPv6 'stateless' mode will always fail immediately when the interface it's using is down. If the interface is up, it will already have completed DAD and dhclient will work.
[test case]
configure ifupdown with:
auto eth0
iface eth0 inet6 auto
dhcp 1
replacing eth0 with the interface to test. Make sure the interface is down, then ifup the interface. isc-dhcp-client will fail claiming that:
no link-local IPv6 address for eth0
Alternately, ifupdown can be bypassed; for an interface that is currently down, do:
$ sudo dhclient -6 -S eth0
which will fail immediately (the -S param uses 'stateless' mode).
[regression potential]
changing isc-dhcp-client to perform PREINIT6 adds a new point of failure for doing DHCPv6, so there is the potential to break existing DHCPv6 clients if the preinit fails. However, 'normal' DHCPv6 already does preinit6 - this only adds it to 'stateless' DHCPv6, so the failure potential should be limited to only users of 'stateless' DHCPv6, and those users are likely already seeing failures as described in this bug.
[other info]
This is related to bug 1633479
Changed in isc-dhcp (Ubuntu Trusty): | |
importance: | Undecided → Medium |
Changed in isc-dhcp (Ubuntu Xenial): | |
importance: | Undecided → Medium |
Changed in isc-dhcp (Ubuntu Artful): | |
importance: | Undecided → Medium |
Changed in isc-dhcp (Ubuntu Bionic): | |
importance: | Undecided → Medium |
assignee: | nobody → Dan Streetman (ddstreet) |
Changed in isc-dhcp (Ubuntu Artful): | |
assignee: | nobody → Dan Streetman (ddstreet) |
Changed in isc-dhcp (Ubuntu Xenial): | |
assignee: | nobody → Dan Streetman (ddstreet) |
Changed in isc-dhcp (Ubuntu Trusty): | |
assignee: | nobody → Dan Streetman (ddstreet) |
this issue was raised before in bug 1633562, and closed as invalid because a side effect of isc-dhcp doing 'preinit6' is clearing any existing global ipv6 addresses from the interface, which definitely is not desirable when using RA to get the address.