<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Possibly answering my own question, RTFM ...</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif"><dt style="color:rgb(0,0,0);font-family:times;font-size:medium"><b>--dhcp-broadcast[=tag:<tag>[,tag:<tag>]]</b></dt><dd style="color:rgb(0,0,0);font-family:times;font-size:medium">(IPv4 only) When all the given tags appear in the tag set, always use broadcast to communicate with the host when it is unconfigured. It is permissible to supply no tags, in which case this is unconditional. Most DHCP clients which need broadcast replies set a flag in their requests so that this happens automatically, some old BOOTP clients do not.</dd><div><br></div><div>Anyone with experience know that this is the case?</div><div><br></div><div>Regards,</div><div>Grant.</div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 19 April 2017 at 09:38, Grant Traynor <span dir="ltr"><<a href="mailto:grant.traynor@switchdin.com" target="_blank">grant.traynor@switchdin.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Hi,</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">I'm having an issue with the DHCP Server in dnsmasq. I'm using it with NetworkManager to support sharing of internet connections between dynamically plugged Ethernet interfaces (USB Ethernet Adaptors hotplugged / unplugged into a RaspberryPi).</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">NetworkManager sets up dnsmasq to serve on the interface when it's plugged in. It runs multiple dnsmasq instances, one for each interface as it comes and goes. dnsmasq is being run by NetworkManager as follows:</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default"><font face="monospace, monospace">/usr/sbin/dnsmasq --conf-file --no-hosts --keep-in-foreground --bind-interfaces --except-interface=lo --clear-on-reload --strict-order --listen-address=10.42.1.1 --dhcp-range=10.42.1.10,10.42.<wbr>1.254,60m --dhcp-option=option:router,<wbr>10.42.1.1 --dhcp-lease-max=50 --pid-file=/var/run/nm-<wbr>dnsmasq-eth1.pid<br></font></div><div><br></div><div><br></div><div><div class="gmail_default" style="font-family:verdana,sans-serif">​This all seems to work fine on the FIRST time a DHCP address is offered. But when the raspberrypi is rebooted, or ethernet devices are enabled and disabled, the subnet for each interface can change. This doesn't seem to be an issue until a client attempts to renew it's IP address. The client makes a DHCP request to the server using the TCP broadcast address as expected.​</div></div><div><br></div><div><div><font face="monospace, monospace" size="1">23:26:56.002026 00:03:ac:0c:92:f9 (oui Unknown) > Broadcast, ethertype IPv4 (0x0800), length 351: (tos 0x0, ttl 64, id 0, offset 0, flags [none], proto UDP (17), length 337)</font></div><div><font face="monospace, monospace" size="1">    <font color="#cc0000"><b>0.0.0.0.bootpc > 255.255.255.255.bootps</b></font>: BOOTP/DHCP, Request from 00:03:ac:0c:92:f9 (oui Unknown), length 309, xid 0x6ec92a2c, secs 12263, Flags [none]</font></div><div><font face="monospace, monospace" size="1">          Client-Ethernet-Address 00:03:ac:0c:92:f9 (oui Unknown)</font></div><div><font face="monospace, monospace" size="1">          Vendor-rfc1048 Extensions</font></div><div><font face="monospace, monospace" size="1">            Magic Cookie 0x63825363</font></div><div><font face="monospace, monospace" size="1">            DHCP-Message Option 53, length 1: Discover</font></div><div><font face="monospace, monospace" size="1">            Client-ID Option 61, length 7: ether 00:03:ac:0c:92:f9</font></div><div><font face="monospace, monospace" size="1" color="#ff0000">            Requested-IP Option 50, length 4: 10.42.1.96</font></div><div><font face="monospace, monospace" size="1">            MSZ Option 57, length 2: 576</font></div><div><font face="monospace, monospace" size="1">            Parameter-Request Option 55, length 7:</font></div><div><font face="monospace, monospace" size="1">              Subnet-Mask, Default-Gateway, Domain-Name-Server, Hostname</font></div><div><font face="monospace, monospace" size="1">              Domain-Name, BR, NTP</font></div><div><font face="monospace, monospace" size="1">            Vendor-Class Option 60, length 12: "udhcp 1.22.1"</font></div><div><font face="monospace, monospace" size="1">            Hostname Option 12, length 21: "<div class="gmail_default" style="display:inline">​<<redacted>></div>"</font></div><div><br></div><div><div class="gmail_default" style="font-family:verdana,sans-serif">​But dnsmasq appears to generate a response to the requested IP, effectively assuming that the client is listening on that address, which doesn't necessarily seem to be the case.​</div></div><div><br></div><div><font face="monospace, monospace" size="1">23:26:56.002780 00:e0:4c:68:01:e4 (oui Unknown) > 00:03:ac:0c:92:f9 (oui Unknown), ethertype IPv4 (0x0800), length 342: (tos 0xc0, ttl 64, id 38232, offset 0, flags [none], proto UDP (17), length 328)</font></div><div><font face="monospace, monospace" size="1">    <font color="#ff0000">10.42.1.1.bootps > 10.42.1.96.bootpc</font>: BOOTP/DHCP, Reply, length 300, xid 0x6ec92a2c, secs 12263, Flags [none]</font></div><div><font face="monospace, monospace" size="1">          Your-IP 10.42.1.96</font></div><div><font face="monospace, monospace" size="1">          Server-IP 10.42.1.1</font></div><div><font face="monospace, monospace" size="1">          Client-Ethernet-Address 00:03:ac:0c:92:f9 (oui Unknown)</font></div><div><font face="monospace, monospace" size="1">          Vendor-rfc1048 Extensions</font></div><div><font face="monospace, monospace" size="1">            Magic Cookie 0x63825363</font></div><div><font face="monospace, monospace" size="1">            DHCP-Message Option 53, length 1: Offer</font></div><div><font face="monospace, monospace" size="1">            Server-ID Option 54, length 4: 10.42.1.1</font></div><div><font face="monospace, monospace" size="1">            Lease-Time Option 51, length 4: 3600</font></div><div><font face="monospace, monospace" size="1">            RN Option 58, length 4: 1800</font></div><div><font face="monospace, monospace" size="1">            RB Option 59, length 4: 3150</font></div><div><font face="monospace, monospace" size="1">            Subnet-Mask Option 1, length 4: 255.255.255.0</font></div><div><font face="monospace, monospace" size="1">            BR Option 28, length 4: 10.42.1.255</font></div><div><font face="monospace, monospace" size="1">            Domain-Name-Server Option 6, length 4: 10.42.1.1</font></div><div><font face="monospace, monospace" size="1">            Default-Gateway Option 3, length 4: 10.42.1.1</font></div></div><div><br></div><div><div class="gmail_default" style="font-family:verdana,sans-serif">Should the response not go back to 10.42.1.255 or some other broadcast address? It appears as though the uDHCP client of TCP stack on the client is ignoring the response as it does not assume that it's requested IP address has in fact been allocated to it?</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">I'm a relative NOOB on this stuff, so I'd appreciate any guidance anyone can offer.</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Kind Regards,</div><div class="gmail_default" style="font-family:verdana,sans-serif">Grant.​</div><br></div>-- <br><div class="m_-2432075832492293221gmail_signature"><div dir="ltr"><div><div dir="ltr"><div style="color:rgb(0,0,0);font-family:helvetica">Grant Traynor</div><div style="color:rgb(0,0,0);font-family:helvetica">Chief Technology Officer</div><div style="color:rgb(0,0,0);font-family:helvetica">SwitchDin Pty Ltd</div><div style="color:rgb(0,0,0);font-family:helvetica">Mob <a href="tel:+61%20428%20408%20558" value="+61428408558" target="_blank">+61.428408558</a></div><div style="color:rgb(0,0,0);font-family:helvetica"><a href="mailto:grant.traynor@switchdin.com" style="color:rgb(17,85,204)" target="_blank"><span>grant.traynor@switchdin.com</span></a></div><div style="color:rgb(0,0,0);font-family:helvetica"><a href="http://switchd.in/" style="color:rgb(17,85,204)" target="_blank">http://www.switchdin.com/</a></div><div style="color:rgb(0,0,0);font-family:helvetica"><a href="https://au.linkedin.com/in/grant-traynor-636b095" style="color:rgb(17,85,204)" target="_blank">linkedin.com/in/grant-traynor-<wbr>636b095</a></div><div style="color:rgb(0,0,0);font-family:helvetica"><br></div><div><font color="#000000" face="Helvetica">Level 2, Building B, 91 Parry Street, Newcastle West, NSW, 2302</font><br></div><div style="color:rgb(0,0,0);font-family:helvetica"><br></div><div style="color:rgb(0,0,0);font-family:helvetica"><div style="margin:0px;font-size:11px;font-family:arial"><font color="#a9a9a9">This email and any attachments are proprietary and confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily reflect or represent those of SwitchDin Pty Ltd. If you have received this email in error, please let us know immediately by reply email and delete it from your system. You may not use, disseminate, distribute or copy this message nor disclose its contents to anyone. </font></div><div style="margin:0px;font-size:11px;font-family:arial"><font color="#a9a9a9">SwitchDin Pty Ltd (ABN 29 154893857) PO Box 1165, Newcastle NSW 2300 Australia</font></div></div></div></div></div></div>
</div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div style="color:rgb(0,0,0);font-family:Helvetica">Grant Traynor</div><div style="color:rgb(0,0,0);font-family:Helvetica">Chief Technology Officer</div><div style="color:rgb(0,0,0);font-family:Helvetica">SwitchDin Pty Ltd</div><div style="color:rgb(0,0,0);font-family:Helvetica">Mob +61.428408558</div><div style="color:rgb(0,0,0);font-family:Helvetica"><a href="mailto:grant.traynor@switchdin.com" style="color:rgb(17,85,204)" target="_blank"><span>grant.traynor@switchdin.com</span></a></div><div style="color:rgb(0,0,0);font-family:Helvetica"><a href="http://switchd.in/" style="color:rgb(17,85,204)" target="_blank">http://www.switchdin.com/</a></div><div style="color:rgb(0,0,0);font-family:Helvetica"><a href="https://au.linkedin.com/in/grant-traynor-636b095" style="color:rgb(17,85,204)" target="_blank">linkedin.com/in/grant-traynor-636b095</a></div><div style="color:rgb(0,0,0);font-family:Helvetica"><br></div><div><font color="#000000" face="Helvetica">Level 2, Building B, 91 Parry Street, Newcastle West, NSW, 2302</font><br></div><div style="color:rgb(0,0,0);font-family:Helvetica"><br></div><div style="color:rgb(0,0,0);font-family:Helvetica"><div style="margin:0px;font-size:11px;font-family:Arial"><font color="#a9a9a9">This email and any attachments are proprietary and confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily reflect or represent those of SwitchDin Pty Ltd. If you have received this email in error, please let us know immediately by reply email and delete it from your system. You may not use, disseminate, distribute or copy this message nor disclose its contents to anyone. </font></div><div style="margin:0px;font-size:11px;font-family:Arial"><font color="#a9a9a9">SwitchDin Pty Ltd (ABN 29 154893857) PO Box 1165, Newcastle NSW 2300 Australia</font></div></div></div></div></div></div>
</div>