HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux spn-python 5.15.0-89-generic #99-Ubuntu SMP Mon Oct 30 20:42:41 UTC 2023 x86_64
User: arjun (1000)
PHP: 8.1.2-1ubuntu2.20
Disabled: NONE
Upload Files
File: //snap/lxd/29619/share/openvswitch/scripts/ovs-bugtool-get-port-stats
#! /bin/bash

#Iterate through each port of every bridge and print
#the port statistics

for bridge in `ovs-vsctl -- --real list-br`
do
    echo "${bridge} : "
    echo "  ${bridge} : `ovs-vsctl get interface ${bridge} statistics`"
    for iface in `ovs-vsctl list-ifaces ${bridge}`
    do
        echo "  ${iface} : `ovs-vsctl get interface ${iface} statistics`"
    done
    echo -e "\n"
done