Proxmox Network - vnstat

scott.ehas

Active Member
Oct 5, 2017
11
0
41
36
Hello,

The vnstat command is not collecting information properly on Proxmox. We are trying to match the bandwidth usage that is collected on the port vs the usage collected on the system. When I run vnstat I get very small totals from the eth0 interface that's bridge into vmbr0.

When I run the live sampling I get the proper usage, but it's not being reflected. This is only happening on the Proxmox host, and am wondering if anyone has experienced this same issue.

root@proxmox:~# vnstat -tr
508387 packets sampled in 5 seconds
Traffic average for eth0

rx 45.70 Mbit/s 48073 packets/s
tx 562.30 Mbit/s 53604 packets/s

root@proxmox:~# vnstat -i eth0
Database updated: Tue Dec 11 09:58:53 2018

eth0 since 11/01/2018

rx: 40.47 GiB tx: 146.09 GiB total: 186.56 GiB

monthly
rx | tx | total | avg. rate
------------------------+-------------+-------------+---------------
Nov '18 40.47 GiB | 146.09 GiB | 186.56 GiB | 603.79 kbit/s
Dec '18 0 KiB | 0 KiB | 0 KiB | 0.00 kbit/s
------------------------+-------------+-------------+---------------
estimated -- | -- | -- |

daily
rx | tx | total | avg. rate
------------------------+-------------+-------------+---------------
yesterday 0 KiB | 0 KiB | 0 KiB | 0.00 kbit/s
today 0 KiB | 0 KiB | 0 KiB | 0.00 kbit/s
------------------------+-------------+-------------+---------------
estimated -- | -- | -- |
 
It's likely that you are running some old version of vnStat and the MaxBandwidth setting in /etc/vnstat.conf has a value much smaller than what the actual maximum bandwidth is. Looking at the -tr output, I'm guessing the MaxBandwidth setting could currently be set at 100 Mbit which results vnStat in discarding any readings that exceed that as invalid and that's why you end up having inconsistent results.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!