viewing stats of VFs (which were created via mlx5_num_vfs sysfs entry)

I create 2 VFs by writing 2 into

/pci/devices/0000:83:00.1/mlx5_num_vfs

I do see these VF interfaces with

p link show eth0

7: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1000

link/ether 24:8a:07:bc:59:ad brd ff:ff:ff:ff:ff:ff

vf 0 MAC 00:00:00:00:00:00, spoof checking off, link-state auto

vf 1 MAC 00:00:00:00:00:00, spoof checking off, link-state auto

How can I see statistics of the two VFs ?

It seems that “ip -s link show eth0” does not show these stats; this is the output:

7: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1000

link/ether 24:8a:07:bc:59:ad brd ff:ff:ff:ff:ff:ff

RX: bytes packets errors dropped overrun mcast

884070 2585 0 0 0 6158

TX: bytes packets errors dropped carrier collsns

0 0 0 0 0 0

vf 0 MAC 00:00:00:00:00:00, spoof checking off, link-state auto

vf 1 MAC 00:00:00:00:00:00, spoof checking off, link-state auto

Hi Kevin,

From our MLNX-OFED UM please see:

3.1.1.3.2SR-IOV Counters

•Physical Function can also read Virtual Functions’ port counters through sysfs located under:

For mlx5 drivers - # /sys/class/net/<interface_name>/device/sriov//stats/

Add on resources:

3.1.1.3.3 ethtool Counters

Sophie.