[Dnsmasq-discuss] No unsolicited RAs on interface that doesn't exist at startup

Maarten de Vries maarten+dnsmasq at m.de-vri.es
Thu May 10 21:07:52 BST 2018


I noticed that dnsmasq often wasn't sending any unsolicited RAs for me.

This turned out to happen when the interface (a bridge interface) wasn't
created yet at the time dnsmasq started. When dnsmasq is started after
the interface is created, it sends RAs as expected. I assume this also
extends to other types of virtual interfaces that are created after
dnsmasq starts.

Digging into the source, it seems to be caused by a missing call to
ra_start_unsolicited for non-template contexts in construct_worker from
src/dhcp6.c. The attached patch adds that call, but only if the
interface index or address changed to prevent doing fast RAs for no reason.

I tested it on my own server and it appears to work as expected. When
the interface is created and configured, dnsmasq does fast RAs for a
while and then settles into slow RAs.

Kind regards,

-- Maarten

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Start-unsolicited-RAs-for-non-template-contexts.patch
Type: text/x-patch
Size: 857 bytes
Desc: not available
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20180510/085f5515/attachment.bin>


More information about the Dnsmasq-discuss mailing list