<div dir="ltr">Nova is only responsible for creating the interface and plugging it into the OVS bridge. It's the neutron agent (or alternative neutron backend like OVN) responsible for setting up all of the flows.<div><br></div><div>Here is a hacky script that I had used to create and delete a bunch of ports like Nova would that you can probably start with: <a href="http://paste.openstack.org/show/609478/">http://paste.openstack.org/show/609478/</a></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, May 12, 2017 at 4:25 AM, duhongwei <span dir="ltr"><<a href="mailto:duhongwei@qiniu.com" target="_blank">duhongwei@qiniu.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><br></div><div>Thanks Kevin!</div><div><br></div><div>I'll dig into neutron.agent.linux.interface to see how it works. Before that, would you give me any previews about what steps should be taken to add a veth to a existed Neutron network?</div><div><br></div><div>Furthermore, is it Neutron who add a veth to ovs bridge or is it the Neutron caller? (such as Nova)</div><div><br></div><div>Who's adding flows to ovs bridge? Neutron or caller?</div><div><u></u><div><br></div><div>Regards,</div><div>Dastan </div><div> </div><div style="font:Verdana normal 14px;color:#000"><div style="FONT-SIZE:12px;FONT-FAMILY:Arial Narrow;padding:2px 0 2px 0">------------------ Original --<wbr>----------------</div><div style="FONT-SIZE:12px;background:#efefef;padding:8px"><div id="m_-1019438340614061572menu_sender"><b>From: </b> "Kevin Benton"<kevin@benton.pub>;</div><div><b>Date: </b> Fri, May 12, 2017 10:45 AM</div><div><b>To: </b> "duhongwei"<<a href="mailto:duhongwei@qiniu.com" target="_blank">duhongwei@qiniu.<wbr>com</a>>; </div><div><b>Cc: </b> "openstack"<<a href="mailto:openstack@lists.openstack.org" target="_blank">openstack@lists.<wbr>openstack.org</a>>; "Vallachorum Tyranorum"<<a href="mailto:ardeleandanflorin@gmail.com" target="_blank">ardeleandanflorin@<wbr>gmail.com</a>>; </div><div><div class="h5"><div><b>Subject: </b> Re: [Openstack] How to utilize Neutron independently with veths</div></div></div></div><div><div class="h5"><div> </div><div dir="auto">You want to look in neutron.agent.linux.interface to see how things are plugged into OVS. That's the module used by the L3 agent to plug into OVS/linux bridge/etc. <div dir="auto"><br></div><div dir="auto">There is a well defined interface name format corresponding to the port ID and the port ID, Mac address, and a couple of other things I can't recall are set in ovsdb to help the agent identify the port as something it should care about. </div></div><div class="gmail_extra"><br><div class="gmail_quote">On May 9, 2017 04:49, "duhongwei" <<a href="mailto:duhongwei@qiniu.com" target="_blank">duhongwei@qiniu.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><br></div><div><u></u><div>Thanks Dan!</div><div><br></div><div>I have to write a customized CNI plugin for our product, so it's better if I know more operation details about how to interact with Neutron manually (consider myself as Nova). Therefore Kuryr is not my best option right now, but it's cool!</div><div><br></div><div>Regards,</div><div>Dastan</div><div> </div><div style="font:Verdana normal 14px;color:#000"><div style="FONT-SIZE:12px;FONT-FAMILY:Arial Narrow;padding:2px 0 2px 0">------------------ Original --<wbr>----------------</div><div style="FONT-SIZE:12px;background:#efefef;padding:8px"><div id="m_-1019438340614061572m_-5672911627170774859menu_sender"><b>From: </b> "Vallachorum Tyranorum"<<a href="mailto:ardeleandanflorin@gmail.com" target="_blank">ardeleandanflorin@g<wbr>mail.com</a>>;</div><div><b>Date: </b> Tue, May 9, 2017 04:08 PM</div><div><b>To: </b> "duhongwei"<<a href="mailto:duhongwei@qiniu.com" target="_blank">duhongwei@qiniu.c<wbr>om</a>>; "openstack"<<a href="mailto:openstack@lists.openstack.org" target="_blank">openstack@lists.op<wbr>enstack.org</a>>; </div><div></div><div><b>Subject: </b> Re: [Openstack] How to utilize Neutron independently with veths</div></div><div> </div><div dir="ltr">Hi,<div><br></div><div>Please take a look at <a href="https://wiki.openstack.org/wiki/Kuryr" target="_blank">Kuryr</a>. Maybe this is what you are looking for.</div><div><br></div><div>Dan. </div></div><br><div class="gmail_quote"><div dir="ltr">On Tue, May 9, 2017 at 10:17 AM duhongwei <<a href="mailto:duhongwei@qiniu.com" target="_blank">duhongwei@qiniu.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>Hi everyone,</div><div><br></div><div>I'm new to OpenStack and currently interested in the Neutron part of it. What I'm seeking is some advice about how to utilize Neutron independently, to build a virtual network, for Docker containers maybe.</div><div><br></div><div>Suppose I've already got Neutron and Keystone installed on controller node and compute nodes. I guess the following steps are required to test a virtual network.</div><div><br></div><div>1) create a <i>network</i></div><div>2) create a <i>subnet</i></div><div>3) create two pairs of veths (each pair represents a vm)</div><div><i>for each pair of them</i>:</div><div>4) create a <i>port </i>for one end of the veth pair (passing veth's mac address as a parameter)</div><div>5) attach another end of the veth pair to ovs bridge</div><div>6) ping from one veth pair to another</div><div><br></div><div>The above is my general idea, don't know if it is correct and don't know the operation details either.</div><div>Expecting your suggestions, any links are appreciated.</div><div><br></div><div>Regards,</div><div>Dastan</div></div><div><u></u><u></u></div>______________________________<wbr>_________________<br>
Mailing list: <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
Post to     : <a href="mailto:openstack@lists.openstack.org" target="_blank">openstack@lists.openstack.org</a><br>
Unsubscribe : <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
</blockquote></div>

</div><u></u></div><br>______________________________<wbr>_________________<br>
Mailing list: <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
Post to     : <a href="mailto:openstack@lists.openstack.org" target="_blank">openstack@lists.openstack.org</a><br>
Unsubscribe : <a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi<wbr>-bin/mailman/listinfo/openstac<wbr>k</a><br>
<br></blockquote></div></div>

</div></div></div><u></u></div></blockquote></div><br></div>