defining a static host identifier in ipv6

Paul Selkirk pselkirk at isc.org
Wed Mar 17 21:04:22 UTC 2010


> Date: Wed, 17 Mar 2010 01:47:59 -0700 (PDT)
> From: Andrew Daviel <advax at triumf.ca>
> 
> As far as I can tell, dhcpd defaults to duid-llt so that the client DUID 
> is different every time dhclient is started. It appears to be saved in 
> the client lease file, so that if I do not delete that, I can extract the 
> DUID from the lease file and use it in the server config to get
> a static address.
> 
> This seems a ludicrous way to do things.
> 
> Have I overlooked something obvious ?

In 4.1.1, we added a -D option, e.g. to send DUID-LL:

    dhclient -6 -DLL

For older clients, you can add this to dhclient6.conf:

    send dhcp6.client-id = concat(00:03:00, hardware);

> Is there a way to get the IPv4 type behaviour, where I can just list 
> clients by MAC address and get a static IPv6 address assigned ?

There isn't a precise analog to the "hardware" keyword in v6, because
the DHCPv6 packet doesn't have a 'chaddr' field, so link-layer
information is lost when a packet passes through a relay.  However, if
you can get the client to send a DUID-LL through either of the above
methods, you can do something like the following in dhcpd6.conf:

host linksys1 {
        host-identifier option dhcp6.client-id 00:03:00:01:00:1d:7e:2d:31:55;
	fixed-address6 2001:0:0:1::400;
}

				paul



More information about the dhcp-users mailing list