How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform? yum install

Hits: 139

How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform?

ovs-tcpdump

Regular Linux utilities can’t monitor everything that goes on inside OpenVswitch. The standard tcpdump utility can dump from devices that it knows about but not what’s going on inside the OpenVswitch. You can install ovs-tcpdump and use it similar to the regular utility.

See the original article that I wrote where I work at Octopus Computer Solutions

We are doing this as part of the project to install Redhat Openstack with DPDK and VXLAN. We need to monitor how an instance communicates with the Controllers and each other.

Your servers need to be registered with Redhat as Openstack, so that you can access the Redhat Repositories.
SO run:
$ subscription-manager attach –pool=YOURPOOL-OPENSTACK_ID

Ovs-tcpdump comes as part of the package openvswitch-test but this requires python-openvswitch
These are not stored in the same repository, so you need to enable both of the following:

$ yum-config-manager –enable rhel-7-server-openstack-13-devtools-rpms
$ yum-config-manager –enable rhel-7-server-openstack-13-rpms
$ yum makecache
$ yum install python-openvswitch
$ yum install openvswitch-test

You can now run
$ ovs-tcpdump -i <interface name> <other parameters>
It accepts other parameters like tcpdump, but it doesn’t accept “any” for insterface name, since you can only dump from one interface at a time.
You can see the interface name via the command:
$ ovs-vsctl show
​​​​​​​

Octopus Computer Solutions is a Red Hat business partner. We deploy OpenStack and OpenShift throughout Israel and the world.

 

 

SOLUTION IN PROGRESS – Updated  –

Environment

Open vSwitch 2.6.1
Open vSwitch 2.9

Issue

How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform?

Resolution

Warning: Using ovs-tcpdump may significantly lower the performance of the virtual switch especially in deployments with DPDK. ovs-tcpdump creates a mirror which sends all mirrored user space packets to the kernel. In scenarios with high traffic, this will consume lots of time in kernel space and may thus affect OVS DPDK performance.

ovs-tcpdump is shipped by RPM openvswitch-test.

Newer versions of OVS (2.9 and beyond)

Enable required repositories, then run:

yum install openvswitch-test
ovs-tcpdump -i <interface name> <other parameters>

 

How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform? SOLUTION IN PROGRESS – Updated February 8 2019 at 8:55 AM – English Environment Open vSwitch 2.6.1 Open vSwitch 2.9 Issue How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform? Resolution Warning: Using ovs-tcpdump may significantly lower the performance of the virtual switch especially in deployments with DPDK. ovs-tcpdump creates a mirror which sends all mirrored user space packets to the kernel. In

Then register server and attach pool

subscription-manager attach –pool=YOURPOOL_ID

yum makecache

yum search openvswitch-test
Loaded plugins: product-id, search-disabled-repos, subscription-manager
==================================================================== N/S matched: openvswitch-test =====================================================================
openvswitch-test.noarch : Open vSwitch testing utilities

Name and summary matches only, use “search all” for everything.
[root@ocs3-compute-21 ~]# yum install openvswitch-test

needs python-openvswitch

yum-config-manager –enable rhel-7-server-openstack-13-rpms

yum makecache

then run ovs-tcpdump -i br-ex

 

it works similar to tcpdump but does not support any for all interfaces

 

 

yum-config-manager –enable rhel-7-server-openstack-13-devtools-rpms

Source: How to use ovs-tcpdump on vhost-user interfaces in Red Hat OpenStack Platform?