<div dir="ltr"><div>Hello,</div><div><br></div>I want to use the same idea as the following link:<div><br></div><div><a href="https://techandtrains.com/2014/02/08/running-open-vswitch-in-network-namespace/">https://techandtrains.com/2014/02/08/running-open-vswitch-in-network-namespace/</a><br></div><div><br></div><div><br></div><div>But I still have a problem to trace packets. Is there any other way to trace packets in OVS? </div><div><br></div><div>Thanks</div><div><br></div><div><br></div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 1, 2018 at 12:23 PM, Ben Pfaff <span dir="ltr"><<a href="mailto:blp@ovn.org" target="_blank">blp@ovn.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Oh, and why are you running multiple instances of OVS? It's unusual.<br>
<div class="HOEnZb"><div class="h5"><br>
On Thu, Feb 01, 2018 at 09:22:31AM -0800, Ben Pfaff wrote:<br>
> The rundir for OVS and for ovs-appctl should match. You can do that by<br>
> defining OVS_RUNDIR in the environment for each one, otherwise you end<br>
> up having to give full paths.<br>
><br>
> On Thu, Feb 01, 2018 at 11:09:42AM -0500, Myra Sh wrote:<br>
> > Thank you for your reply.<br>
> ><br>
> > I tried:<br>
> > OVS_RUNDIR=$(pwd)<br>
> > exportOVS_RUNDIR<br>
> > in all nodes.<br>
> ><br>
> ><br>
> > After that,when I run for example: *"ovs-appctl ofproto/trace br1<br>
> > in_port=1"* on bridge1, I receive the following message:<br>
> ><br>
> > *WARN|failed to connect to .../n1.conf/ovs-vswitchd.50.<wbr>ctl*<br>
> ><br>
> ><br>
> ><br>
> > there is no ovs-vswitch.50.ctl in $(pwd) directory.<br>
> ><br>
> > I found *ovs-vswitchd.50.ctl* in */usr/local/var/run/<wbr>openvswitch/ *directory<br>
> > and after that:<br>
> ><br>
> > *ovs-appctl -t /usr/local/var/run/<wbr>openvswitch/ ovs-vswitchd.50.ctl<br>
> > bridge/dump-flows br1 *<br>
> ><br>
> > result:<br>
> ><br>
> > *unknown bridge*<br>
> > *ovs-appctl: /usr/local/var/run/<wbr>openvswitch/ ovs-vswitchd.50.ctl :server<br>
> > returend an error*<br>
> ><br>
> ><br>
> ><br>
> > the mentioned command only works on a specific bridge(br3).<br>
> ><br>
> ><br>
> > So I guess I should try to find the correct ovs-vswitchd.*.ctl for each<br>
> > bridge but it's not reasonable when I have several OVSs.<br>
> ><br>
> > Do you have any suggestion in this case?<br>
> ><br>
> > Is there any other way to trace the packets in OVS?<br>
> ><br>
> ><br>
> ><br>
> ><br>
> ><br>
> > On Wed, Jan 31, 2018 at 4:15 PM, Ben Pfaff <<a href="mailto:blp@ovn.org">blp@ovn.org</a>> wrote:<br>
> ><br>
> > > On Wed, Jan 31, 2018 at 02:53:25PM -0500, Myra Sh wrote:<br>
> > > > Hello,<br>
> > > ><br>
> > > > I run several instances of OVS and I am using the following command and<br>
> > > > path to configure them:<br>
> > > ><br>
> > > > ovs-vsctl --db=unix:$(pwd)/db.sock add-br br0<br>
> > > ><br>
> > > > The problem in having several instances is that when I want to run<br>
> > > > "ovs-appctl ..." to trace packets, I have to define a path or target for<br>
> > > > this command.<br>
> > > ><br>
> > > > Do you have any suggestion that how I can define this target path for<br>
> > > each<br>
> > > > OVS in the mentioned scenario?<br>
> > > ><br>
> > > > Should I check for any ovs-vswitch.*.ctl file and put that in the target<br>
> > > > part?<br>
> > ><br>
> > > It sounds like you should run something like "OVS_RUNDIR=$(pwd); export<br>
> > > OVS_RUNDIR".<br>
> > ><br>
</div></div></blockquote></div><br></div></div>