[Dnsmasq-discuss] dhcpv6 problem with static allocations and "no addresses available"

Simon Kelley simon at thekelleys.org.uk
Wed Oct 21 22:51:32 BST 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256



On 20/10/15 22:33, Carlos Carvalho wrote:
> I'm stumbling on an important problem that looks like a bug in
> dnsmasq. Clients declared statically in a zone are being denied
> their address with the message "no addresses available":
> 
> Oct 20 09:56:10 dnsmasq-dhcp[18342]: 6947286 available DHCPv6
> subnet: 2801:82:80ff:7f05::/64 Oct 20 09:56:10 dnsmasq-dhcp[18342]:
> 6947286 vendor class: 40712 Oct 20 09:56:10 dnsmasq-dhcp[18342]:
> 6947286 client MAC address: 10:bf:48:71:65:99 Oct 20 09:56:10
> dnsmasq-dhcp[18342]: 6947286 DHCPSOLICIT(meteo)
> 00:01:00:01:1d:a8:3f:4a:10:bf:48:71:65:99 Oct 20 09:56:10
> dnsmasq-dhcp[18342]: 6947286 DHCPADVERTISE(meteo)
> 00:01:00:01:1d:a8:3f:4a:10:bf:48:71:65:99 no addresses available 
> Oct 20 09:56:10 dnsmasq-dhcp[18342]: 6947286 tags: known, dhcpv6,
> meteo Oct 20 09:56:10 dnsmasq-dhcp[18342]: 6947286 sent size: 14
> option:  1 client-id  00:01:00:01:1d:a8:3f:4a:10:bf:48:71:65:99 Oct
> 20 09:56:10 dnsmasq-dhcp[18342]: 6947286 sent size: 10 option:  2
> server-id  00:03:00:01:00:24:8c:0c:37:90 Oct 20 09:56:10
> dnsmasq-dhcp[18342]: 6947286 sent size: 24 option: 13 status  2 no
> addresses available
> 
> Note that the client is recognized because the known tag is set.
> The dhcp config is the following:
> 
> interface=meteo dhcp-range=::,constructor:meteo,static,infinite 
> enable-ra dhcp-range=192.168.5.1,static
> 
> dhcp-host=cobb,192.168.5.11,[2801:82:80ff:7f05:12bf:48ff:fe71:6599],10
:bf:48:71:65:99,id:00:01:00:01:1d:a8:3f:4a:10:bf:48:71:65:99
>
> 
[other dhcp-host declarations]
> 
> dhcp-host=elbrus,192.168.5.75,[2801:82:80ff:7f05:12bf:48ff:fe79:aa07],
10:bf:48:79:aa:07,id:*
>
>  At first I tried to use only id:* for all machines but started
> getting refusals like the above. I noticed that the DUID was
> changing, so I fixed it in the client. Still got sporadic refusals
> (it doesn't happen everytime?!). Then I put the full id in the
> config as shown above for host cobb. Even then dnsmasq is refusing
> it. How can this be? Also, the refusal is for IPv6 only.

Maybe there are leases for old UIDS and the static address still the
database?
> 
> There's no collision with other declarations omitted above, I
> checked with grep.
> 
> This is important because these hosts are diskless and without the
> IP they cannot access the root server and thus don't boot.
> 
> On a related issue, is it possible to always use only the hardware
> address for dhcpv6 and not the full DUID? In my case it may happen
> when diffent programs are used for requests, such as UEFI firmware
> and linux in diskless stations. Since the machine doesn't have
> permanent storage it's difficult to keep the DUID constant.


Yes, in general. The DHCPv6 spec makes it hard, but dnsmasq will allow
you to use just the MAC address to identify DHCP hosts even for
DHCPv6. If you are using a DHCPv6 relay, then the relay has to add an
option which specifies the MAC address. If  network is directly
connected to the DHCP server, then it should Just Work with recent
dnsmasq releases.


Cheers,

Simon.

> 
> ______________


_________________________________
> Dnsmasq-discuss mailing list 
> Dnsmasq-discuss at lists.thekelleys.org.uk 
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)

iQIcBAEBCAAGBQJWKAjkAAoJEBXN2mrhkTWinloP/2UjS0q//bUIXOp6B7cuo5aF
dIigvb0bOGd4jIQOCqajGoKYA6hwpdCIjX8bZcxGkAYamenH+6rR6lbjPtKNUWSc
+WuYMCVLqZ8OY4d4JME9bRitLPBuvq/cghdm3leWCt/WeFbXxovTAGqPlUvke0bl
Lkkjp4HoB4Sr+TDrhDHZzKnBWVk24cnNXmo86sxGC3ILnjad3eciQHktPjZgwVmA
j1TbcWNiAz2JjmnSZERJTwo6tCBaVF1zynFX6zcLbaPXT8ePWnWCihzcwBHugrPr
/66kODLSZfGbKATJoNpLLOPQhZlXut+ZHiZ4gj6TX7WIQg+ssbm6/9/YHssugtBC
qumvRaajb3Um7SHpkcYyBYZi2kZfNQ1kFRlvdeTIkpj8zt49rsYCaUzbMCtCO0FM
JwJayTTSm/iGkupsE7MAEhoRYBi4I5/5d74l++xJF1Djjmfwf8mSTbFB627ml+9g
z7a092pRXRZlaGGVxt6rMaTG7Ckox2T+lDQ4YvRccAW8PrGFUhAFFVXaW21CLmDK
IPSGWmbvFWoTEKUHXSAcgRri5wBysUhrarhj+EgmmbJ7SuJDJFeraVVnsDbjx6NQ
0t44iqTzxnBZEjb6vzSGFVD4h5Hcn0Z/KMhAnfwdiDXZMmdR3r20Tm86lOgCzOWD
DqlXvyj/+Og7z35vNeFK
=6E6Q
-----END PGP SIGNATURE-----



More information about the Dnsmasq-discuss mailing list