[Dnsmasq-discuss] Noisy DHCPv6 DHCPADVERTISE

Simon Kelley simon at thekelleys.org.uk
Sat Mar 2 18:49:35 UTC 2024


The message can be important (think a mismatch between the address of 
the receiving interface and a dhcp-range, so I wouldn't like to suppress it.

It might be sensible to detect the situation you have (static range in 
scope, no host configured) and suppress it then. It's slightly more 
complicated since there can be more than one address request from the 
client, but that's a detail.


Simon.

 > On 29/02/2024 11:04, Ian Dall wrote:
> I know this is an old thread, but I too find these messages annoying.
> 
> I have:
> 	dhcp-range=set:lan,::,static,constructor:br-lan,slaac,ra-names,12h
> 
> which as far as I can tell is perfectly valid. My unknown IPv6 clients
> get configured with SLAAC/RA, but clients which are known via dhcp-host
> get a DNS record so can be referenced by name (and the same name as
> their IPv4 address). Unfortunately the unknown clients do a DHCPv6
> SOLICIT and get back "no addresses available".
> 
> With "static" mode "no addresses available" is a lower priority error,
> although it could still be of interest because perhaps we expect a
> (known) address to be allocated, but is failing due to different DUID
> types or something (and you would want to know about that).
> 
> So, it would be really nice to be able to optionally quieten these
> messages (with quiet-dhcp6 would be simplest).
> 
> Regards,
> Ian
> 
> 
> On Sun, 2019-06-02 at 09:57 +0200, stappers at stappers.nl wrote:
>> On Sat, Jun 01, 2019 at 08:02:27PM -0700, Sam Edwards wrote:
>>> Hello,
>>>
>>> I have dnsmasq set up to provide IPv6 RAs with the SLAAC bit set,
>>> and also serve select static DHCPv6 leases. Everything is set up and
>>> working correctly, but because only some devices have a static lease
>>> set up, and there is no DHCPv6 pool, my logs fill up with entries from
>>> devices that don't get a lease, reporting that there is no address
>>> available for them.
>>>
>>> Jun  1 19:46:56 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:02:00:00:01:57:72:f6:40:68:e8:c6:6d:4e:8e:bd:fc:34:65:xx:xx:xx,no addresses available
>>> Jun  1 19:47:33 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:1d:b7:03:73:3c:07:54:xx:xx:xx,no addresses available
>>> Jun  1 19:48:12 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:21:4c:7f:01:08:66:98:xx:xx:xx,no addresses available
>>> Jun  1 19:48:57 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:02:00:00:01:57:72:f6:40:68:e8:c6:6d:4e:8e:bd:fc:34:65:xx:xx:xx,no addresses available
>>> Jun  1 19:49:24 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:1d:b7:03:73:3c:07:54:xx:xx:xx,no addresses available
>>> Jun  1 19:50:04 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:21:4c:7f:01:08:66:98:xx:xx:xx,no addresses available
>>> Jun  1 19:50:57 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:02:00:00:01:57:72:f6:40:68:e8:c6:6d:4e:8e:bd:fc:34:65:xx:xx:xx,no addresses available
>>> Jun  1 19:51:15 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:1d:b7:03:73:3c:07:54:xx:xx:xx,no addresses available
>>> Jun  1 19:51:17 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:23:38:5f:28:e0:33:8e:xx:xx:xx,no addresses available
>>> Jun  1 19:51:54 dnsmasq-dhcp[4798]: DHCPADVERTISE(switch0.5) 00:01:00:01:21:4c:7f:01:08:66:98:xx:xx:xx,no addresses available
>>>
>>> I see in the source, around line 899 of src/rfc3315.c that there is
>>> code to suppress these messages when dnsmasq is operating strictly in
>>> stateless IPv6 mode, but that of course doesn't apply to me.
>>>
>>> The question I guess I'm really asking here then, is if the log entry
>>> that's emitted on line 905 of src/rfc3315.c shouldn't be a log6_quiet
>>> instead of a log6_packet, or if there's a feeling that this log line
>>> is important enough to be present at all times.
>>>
>>> Here's the relevant part of my configuration for reference:
>>>
>>> quiet-dhcp
>>> quiet-dhcp6
>>> quiet-ra
>>> enable-ra
>>> ra-param=*,mtu:tun0,high,60
>>
>> At http://thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html is
>>   dhcp-range=[tag:<tag>[,tag:<tag>],][set:<tag>,]<start-IPv6addr>[,<end-IPv6addr>|constructor:<interface>][,<mode>][,<prefix-len>][,<lease time>]
>>
>>   ...
>>
>>   The optional <mode> keyword may be static which tells dnsmasq to enable
>>   DHCP for the network specified, but not to dynamically allocate IP
>>   addresses: only hosts which have static addresses given via --dhcp-host
>>   or from /etc/ethers will be served. A static-only subnet with address
>>   all zeros may be used as a "catch-all" address to enable replies to all
>>   Information-request packets on a subnet which is provided with
>>   stateless DHCPv6, ie --dhcp-range=::,static
>>
>>> dhcp-range=set:Clients-v6,::,constructor:switch0.5,static,slaac,64,24h
>>
>> There is no mode 'static,slaac'.  And mode 'static' is most likely
>> the reason for the reported "no addresses available".
>>
>> If so we, dnsmasq project, have to discuss this manual page snippet
>>
>>   A static-only subnet with address all zeros may be used as a "catch-all"
>>   address to enable replies to all Information-request packets on a subnet
>>   which is provided with stateless DHCPv6, ie --dhcp-range=::,static
>>
>> further. Or maybe not, an Information-request is another request
>> as a request for an address.
>>
>>
>>> dhcp-option=tag:Clients-v6,option6:dns-server,[::]
>>> dhcp-option=tag:Clients-v6,option6:domain-search,example.com
>>
>> And at http://thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html is this
>>   dhcp-host=[<hwaddr>][,id:<client_id>|*][,set:<tag>][,<ipaddr>][,<hostname>][,<lease_time>][,ignore]
>>
>> Now find ',<lease_time>' or ',ignore' in belows  dhcp-host lines.
>>
>>> dhcp-host=3c:07:54:xx:xx:xx,set:Clients-v6,[::5],caesar,caesar.example.com
>>> dhcp-host=id:00:01:00:01:20:69:f8:4b:b8:27:eb:xx:xx:xx,set:Clients-v6,[::7],prince,prince.example.com
>>> dhcp-host=id:00:03:00:01:00:1f:f3:xx:xx:xx,set:Clients-v6,[::9],kitchen.example.com
>>> dhcp-host=22:88:fe:xx:xx:xx,set:Clients-v6,[::235],adiutor,adiutor.example.com
>>> dhcp-host=8e:16:5c:xx:xx:xx,set:Clients-v6,[::91],peel,peel.example.com
>>> dhcp-host=7e:44:1c:xx:xx:xx,set:Clients-v6,[::126],solium,solium.example.com
>>> dhcp-host=fa:76:fc:xx:xx:xx,set:Clients-v6,[::222],fenestram,fenestram.example.com
>>> dhcp-host=id:00:01:00:01:23:f2:35:79:6c:0b:84:xx:xx:xx,set:Clients-v6,[::250],imbrem,imbrem.example.com
>>   
>>
>>
>> Regards
>> Geert Stappers
>> Looking forward to "Yes, now it works also me" messages.
> 
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> https://lists.thekelleys.org.uk/cgi-bin/mailman/listinfo/dnsmasq-discuss
> 




More information about the Dnsmasq-discuss mailing list