GNOME Bugzilla – Bug 684242
dynamic DNS updating does not work for IPv6
Last modified: 2012-12-13 23:42:47 UTC
While dynamic DNS updating works for IPv4, it does not work for IPv6 because NetworkManager does not send the client-host's name in its dhcp request. I have tested this with dnsmasq and am setting up testing to see if the same situation occurs with dhcpd-v6/named. My test was to run wireshark to capture the packets and, while running NetworkManager and then enable an interface with a IPv6 network. I then stopped NetowrkManager and used the "ifup eth0" network script with a slight modification to ifup-eth in the dhclient commandline to change "-H" to "-F". Worked fine! There they were ... the fqdn specification in the dhcpv6 packets. Note ... the lease file showed a lot of additional entries when things work. I do not know if just doing a "send fqdn.fqdn name;" will be sufficent. This testing was done on Fedora 17.
I have duplicated the problem using bind and dhcp instead of dnsmasq. The same results.
The ISC DHCP client has two modes: "adhoc" and "draft". The "adhoc" mode is now deprecated and apparently doesn't work with failover, while the "draft" mode is preferred. The "adhoc" mode used the hostname + a config option to construct the DDNS name, while the "draft" mode uses the FQDN and is preferred. So the question becomes: is anyone actually using the old "adhoc" mode, and would we break anyone by moving to using the FQDN option instead? That's the big question here. Plus, we're not just talking about the ISC DHCP client, we need to figure out what happens with (a) MS DHCP/DNS and (b) WiFi routers with built-in DDNS functionality. I'm really hoping to avoid a "DDNS update method" = [ Disabled, Ad-Hoc, FQDN ] menu anywhere in the UI as that just sucks.
Agreed. The problem is that you do not know just what kind of server is at the other end so a build/compile-time option will not work either. My suggestion: for IPv4 stick with the current approach. For IPv6 add "-F <hostname>" to the command line. Any server implementing IPv6 should expect a fqdn.fqdn <plain-name> ... I cannot picture some old server code suddenly implementing IPv6 and not prepared to handle it. For IPv4 it should be possible to force a switch to "-F" also ... now maybe that could be a build/compile-time options. Interesting, I took a little look at the code and, if I understand, in nm-dhcp-dhclient.c there is function dhclient_start. The only functions that call it are real_ip4_start and real_ip6_start which are also in the same file. Both the real_ip*_start functions are passed a parameter "hostname" which appears never to be used. To me, implementing it for IPv6 should be a given. The question is what to do about IPv4.
I have a patch working. It should be ready "real soon now" and will be posted to the mailing list.
You can attach it here.
soon, soon, I am doing some final testing to make sure that it is as right as I can make it. Also, I have put the "candidate" patch on the mailing list asking for comment/suggestions/whatever and would like to give it a couple of days. If nothing else happens, then I will post my initial version as applied to a git clone. Question: I saw your bugzilla item about having keyfile have precedence over ifcfg-rh. The ifcfg-rh plugin handles a lot of IPV6 and other parameters. Where can I find out what keyfile handles? BTW, a basic test with my modiications but specifying plugin=keyfile works. I am also discovering some other things such as that having a default route with dhcp does not appear to work.
Keyfile handles virtually everything. It exposes the internal NM configuration almost 1:1. The ifcfg-rh plugin is an alternative plugin. „I am also discovering some other things such as that having a default route with dhcp does not appear to work.“ That bug was fixed in 0.9.6 together with a bunch of other IPv6-related bugs. A good reference on IPv6 support and testing is here: https://fedoraproject.org/wiki/Tools/NetworkManager/IPv6
Created attachment 226399 [details] [review] multi-instantiation ehhances so dnsmasq multi-copies can run
Libvirt?
I do not understand your question Pavel.
It looks like you sent a libvirt/something patch to NetworkManager bugzilla.
Created attachment 226814 [details] [review] patch to add support for ipv6 dynamic dns updating As far as that other patch is concerned, I guest I did not have enough coffee or perhaps sleep ,,, it got posted to the wrong place
Added to 'pavlix/dhcp' branch where other pending modifications to DHCP are.
Gene's patch did eventually land in git master: 90b99522d7b35e253926e48f5df8a22270ab7610