<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 4, 2017 at 5:48 PM, Alin Serdean <span dir="ltr">&lt;<a href="mailto:aserdean@cloudbasesolutions.com" target="_blank">aserdean@cloudbasesolutions.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">





<div bgcolor="white" lang="EN-US">
<div class="gmail-m_-6363499933999699071WordSection1">
<p class="MsoNormal"><span style="color:windowtext">Hi Alex,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext">You can send it to <a href="mailto:dev@openvswitch.org" target="_blank">
dev@openvswitch.org</a> or create a new pull request via github. <u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext">Thanks,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext">Alin.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:windowtext"><u></u> <u></u></span></p>
<div style="border-top:none;border-right:none;border-bottom:none;border-left:1.5pt solid blue;padding:0cm 0cm 0cm 4pt">
<div>
<div style="border-right:none;border-bottom:none;border-left:none;border-top:1pt solid rgb(225,225,225);padding:3pt 0cm 0cm">
<p class="MsoNormal"><b><span style="color:windowtext">From:</span></b><span style="color:windowtext"> <a href="mailto:ovs-discuss-bounces@openvswitch.org" target="_blank">ovs-discuss-bounces@<wbr>openvswitch.org</a> [mailto:<a href="mailto:ovs-discuss-bounces@openvswitch.org" target="_blank">ovs-discuss-bounces@<wbr>openvswitch.org</a>]
<b>On Behalf Of </b>Alex Jones<br>
<b>Sent:</b> Tuesday, July 4, 2017 4:00 AM<br>
<b>To:</b> <a href="mailto:ovs-discuss@openvswitch.org" target="_blank">ovs-discuss@openvswitch.org</a><br>
<b>Subject:</b> [ovs-discuss] OVN DHCP implementation ignores broadcast bit<u></u><u></u></span></p>
</div>
</div><div><div class="gmail-h5">
<p class="MsoNormal"><u></u> <u></u></p>
<p>Hi All,<u></u><u></u></p>
<p>  I have OVN up and running (version 2.7), and it is working well except for one case. We have a VM which uses its own IP stack and does not accept unicast DHCP offers. After examining the OVN code, I found that it currently doesn&#39;t support the broadcast
 bit if set by the client.<u></u><u></u></p>
<p>  I didn&#39;t see any bugs regarding this, so I did a patch myself. The patch modifies put_dhcp_options to return 2 if the broadcast bit was set in the DISCOVER/REQUEST, and 1 if not set (both indicate success). Then I modified the current logical flow to check
 if the return code is 1, then execute the current logical flow. I added a new logical flow to handle the broadcast bit set case. If the return value from put_dhcp_options is 2, the new flow is executed which sets the dest MAC and dest IP to broadcast.<u></u><u></u></p>
<p>  I&#39;d like to submit this. Do I just post it here?<u></u><u></u></p>
<p>Alex<u></u><u></u></p>
<p><u></u></p></div></div></div></div></div></blockquote><div><br></div><div>The other simpler approach could be to set &quot;ip4.dst and eth.dst&quot; to broadcast addresses if broadcast bit is set, giaddr and ciaddr is 0 (as per the RFC - <a href="https://www.ietf.org/rfc/rfc2131.txt">https://www.ietf.org/rfc/rfc2131.txt</a>) in the function &quot;pinctrl_handle_put_dhcp_opts&quot; (in ovn/controller/pinctrl.c) and modify ovn-northd.c to not set the eth.dst and ip4.dst fields in the S_SWITCH_IN_DHCP_RESPONSE  pipeline.</div><div><br></div><div>Probably we should also set ip4.dst to giaddr (to support dhcp relay) if it is set.</div><div><br></div><div>Thanks<br></div><div>Numan</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div bgcolor="white" lang="EN-US"><div class="gmail-m_-6363499933999699071WordSection1"><div style="border-top:none;border-right:none;border-bottom:none;border-left:1.5pt solid blue;padding:0cm 0cm 0cm 4pt"><div><div class="gmail-h5"><p> <u></u></p>
</div></div></div>
</div>
</div>

<br>______________________________<wbr>_________________<br>
discuss mailing list<br>
<a href="mailto:discuss@openvswitch.org">discuss@openvswitch.org</a><br>
<a href="https://mail.openvswitch.org/mailman/listinfo/ovs-discuss" rel="noreferrer" target="_blank">https://mail.openvswitch.org/<wbr>mailman/listinfo/ovs-discuss</a><br>
<br></blockquote></div><br></div></div>