On Mon, Aug 05, 2019 at 06:44:46AM -0700, Cooper Lees wrote:
> On Aug 4, 2019, at 11:29 PM, Geert Stappers wrote:
> > On Sun, Aug 04, 2019 at 03:05:45PM -0700, Cooper Lees wrote:
> >> 
       ....
> >> 
> >> Any suggestions I could try / do or is this indeed a bug with dnsmasq?
> >> 
> >> ./src/dnsmasq -x /run/dnsmasq/dnsmasq.pid -u dnsmasq -r 
> >> /run/dnsmasq/resolv.conf -7 /etc/dnsmasq.d,.dpkg-dist,.dpkg-old,.dpkg-new 
> >> --local-service
> > 
> > The    `,.dpkg-dist,.dpkg-old,.dpkg-new` somewhat odd.
> > Probably a side effect of some wildcard expansion.
> > 
> > Check what is inside those  .dpkg-distl.dpkg-old .dpkg-new files.
> > Remove them if there is nothing usefull in. And surely remove
> > them when there is only duplicate configuration.
> 
> This seems to be a default with the raspbian install - There is nothing in 
> /etc/dnsmasq.d
> ```
> cooper@home:~ $ find /etc/dnsmasq.d
> /etc/dnsmasq.d
> /etc/dnsmasq.d/README
> ```
> 
> Removing these and running the daemon has no effect.
> ```
> 31737 dnsmasq   20   0    2244    120      0 R  85.8   0.0   0:15.87 
> ./src/dnsmasq -x /run/dnsmasq/dnsmasq.pid -u dnsmasq -r 
> /run/dnsmasq/resolv.conf --local-service
> ```

I do see the "85.8 procent CPU load".
And that the .dpkg-distl.dpkg-old .dpkg-new files are gone.
 
> > 
> >> ```
> >> Log from starting with HEAD:
            .... 15 log entries ....
> >> ```
> > 
> > Nothing that indicates a 25% CPU load.
> - This is because I added the `quiet-ra` option 
> - Otherwise it's just 10000s `dnsmasq-dhcp[19424]: RTR-ADVERT(eth0.69) 
> 2601:647:4d01:fbf::` lines in logs
> 
> > 
> >> 
> >> Log Messages (without quiet-ra)
> >> ```
> >> Aug  4 14:52:30 home dnsmasq-dhcp[19424]: RTR-ADVERT(eth0.69) 
> >> 2601:647:4d01:fbf::
> >> ```
> > 
> > Even less
> > 
> > Previously
> >> core with continually advertising RAs. Logs and tcpdump confirm it's
> > 
> > Without flooding this mailinglist,
> > please share somehow that data with us.
> > 
> 
> With `dhcp-range=2601:647:4d01:fbf::,ra-names` in the config causes
> 'top' to show a lot of CPU used (>90%):
> ```
> 19492 dnsmasq   20   0   11076   2536   2228 R  93.4   0.1 815:27.43 
> /usr/sbin/dnsmasq -x /run/dnsmasq/dnsmasq.pid -u dnsmasq -r 
> /run/dnsmasq/resolv.conf -7 /etc/dnsmasq.d,.dpkg-dist,.dpkg-old,.dpkg-new 
> --local-service
> ```
> AND tcpdump shows a barrage of RAs being advertised:
> ```
> 06:39:00.390680 IP6 fe80::dea6:32ff:fe02:b43d > ff02::1: ICMP6, router 
> advertisement, length 88
> 06:39:00.391455 IP6 fe80::dea6:32ff:fe02:b43d > ff02::1: ICMP6, router 
> advertisement, length 88
> 06:39:00.392017 IP6 fe80::dea6:32ff:fe02:b43d > ff02::1: ICMP6, router 
> advertisement, length 88
> 06:39:00.392564 IP6 fe80::dea6:32ff:fe02:b43d > ff02::1: ICMP6, router 
> advertisement, length 88
> 06:39:00.393103 IP6 fe80::dea6:32ff:fe02:b43d > ff02::1: ICMP6, router 
> advertisement, length 88
> ```
> - Please look at the timestamps here
> - Milliseconds apart 
 
Acknowledge on that


> >> Config:
> >> ```
> >> # Never forward plain names (without a dot or domain part)
> >> bogus-priv
> >> # Never forward addresses in the non-routed address spaces.
> >> domain-needed
> >> 
> >> # Delays sending DHCPOFFER and proxydhcp replies for at least the 
> >> specified number of seconds.
> >> dhcp-mac=set:client_is_a_pi,B8:27:EB:*:*:*
> >> dhcp-reply-delay=tag:client_is_a_pi,2
> > 
> > Why that delay?
> > What is the effect of removing it?
> - This is a default in the raspbian dnsmasq install
> - Removing this has no effect
 
Acknowledge


> >> # List of all the interfaces for dnsmasq to listen on
> >> # Sample interface line: interface=eth0
> >> interface=eth0
> >> interface=eth0.69
> >> 
> >> # v4 - manually set these options
> >> dhcp-option=option:domain-search,cooperlees.com
> >> dhcp-option=option:router,10.6.9.2
> >> dhcp-range=eth0,192.168.107.10,192.168.107.100,1h
> >> dhcp-range=eth0.69,10.6.9.10,10.6.9.200,24h
> >> 
> >> 
> >> # v6 Sateless RA + Names
> >> # Sample DHCP range line: dhcp-range=2601:647:4d01:fbf::, ra-stateless, 
> >> ra-names
> >> #dhcp-range=2601:647:4d01:fbf::,ra-stateless, ra-names
> >> dhcp-range=2601:647:4d01:fbf::,ra-names
> >> #ra-param=eth0.69,4
> >> quiet-ra
> >> ```
> >> 
> >> Thanks,
> >> Cooper
> > 
> > Please keep us, this mailinglist, informed.
> > 
> 
> I guess it's going to be time to dig into the source code here if
> nothing else in my config looks outside the ordinary.

Configuration
> >> dhcp-range=eth0,192.168.107.10,192.168.107.100,1h
> >> dhcp-range=eth0.69,10.6.9.10,10.6.9.200,24h
> >> dhcp-range=2601:647:4d01:fbf::,ra-names


Manualpage
| 
dhcp-range=[tag:<tag>[,tag:<tag>],][set:<tag>,]<start-addr>[,<end-addr>|<mode>][,<netmask>[,<broadcast>]][,<lease
 time>]
| 
dhcp-range=[tag:<tag>[,tag:<tag>],][set:<tag>,]<start-IPv6addr>[,<end-IPv6addr>|constructor:<interface>][,<mode>][,<prefix-len>][,<lease
 time>] 

Untested new configuration
| dhcp-range=eth0,192.168.107.10,192.168.107.100,1h
| dhcp-range=eth0.69,10.6.9.10,10.6.9.200,24h
| dhcp-range=2601:647:4d01:fbf::,constructor:eth0,ra-names,80
| dhcp-range=2601:647:4d01:fbf:8000::,constructor:eth0.69,ra-names,80

The idea is to have a /80 IPv6 network on each interface.
 

Please report your milage


> Cheers,
> Cooper

Groeten
Geert Stappers
-- 
Leven en laten leven

_______________________________________________
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss

Reply via email to