summaryrefslogtreecommitdiffstats
path: root/src/cni/ovsdpdk/teardown_ovsdpdk.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/cni/ovsdpdk/teardown_ovsdpdk.sh')
-rwxr-xr-xsrc/cni/ovsdpdk/teardown_ovsdpdk.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/cni/ovsdpdk/teardown_ovsdpdk.sh b/src/cni/ovsdpdk/teardown_ovsdpdk.sh
new file mode 100755
index 0000000..857738e
--- /dev/null
+++ b/src/cni/ovsdpdk/teardown_ovsdpdk.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+netns=$1
+containerid=$2
+pid=$(echo $netns | cut -f3 -d"/")
+
+sudo ovs-vsctl del-port br-dpdk vhost-user-$pid
+sudo ip netns exec $pid link delete dummy-$pid
+sudo rm -rf /var/run/cni/netconf-$pid