1 # ovs-replay.py - launch a running OVS configured from dumps
3 This script creates a docker container running a OVS configured
4 with the exact ports, flows, and groups captured from a running
5 netvirt environment. Once the containerized OVS is running you
7 * ovs-appctl ofproto/trace (you need to manually specify the vswitchd socket file...need to fix this)
8 * send packets from the port namespaces created (see them by typeing `ip netns`)
9 * run tcpdump on a port (don't forget -n)
10 * run tcpdump on a flow using: https://github.com/jhershberg/WIP/blob/master/ovs-flow-snoop
16 `sudo docker pull jhershbe/fedora-ovs-replay`
19 $ ./ovs-replay.py --help
20 usage: ovs-replay.py [-h] [--name NAME] flows groups ports show
23 flows path to the flow dump
24 groups path to the groups dump
25 ports path to the ports dump
26 show path to the show dump
29 -h, --help show this help message and exit
30 --name NAME name the container, or "ovs-replay" if option omitted
32 The dumps must be generated such:
33 * flows: ovs-ofctl -OOpenFlow13 dump-flows br-int
34 * groups: ovs-ofctl -OOpenFlow13 dump-group br-int
35 * ports: restconf response of /neutron:neutron/ports
36 * show: ovs-ofctl show br-int