# Debian / Ubuntu sudo apt install vnstat -y # RHEL-based (AlmaLinux / Rocky / RHEL) sudo dnf install vnstat -y # Enable and check the service (daemon creates DB automatically) sudo systemctl enable --now vnstat sudo systemctl status vnstat
# Monthly summary vnstat -m #To select interface vnstat -m -i eth0 # Daily / hourly if needed vnstat -d vnstat -h

MonthRotate:
sudo nano /etc/vnstat.conf
MonthRotate 18

sudo systemctl restart vnstatWith
MonthRotate 18, vnStat treats the statistics window as “billing months” that end on the 18th and reset on the 19th.
# remove DB for an interface (example: eth0) sudo vnstat --remove --force -i eth0 sudo vnstat --add -i eth0 # OR delete DB file directly sudo rm -f /var/lib/vnstat/vnstat.db sudo systemctl restart vnstat
# Install & enable sudo apt install vnstat -y #Debian / Ubuntu sudo dnf install vnstat -y # RHEL-based (AlmaLinux / Rocky / RHEL) sudo systemctl enable --now vnstat # Result vnstat # Change monthly rotate date sudo nano /etc/vnstat.conf MonthRotate 10 sudo systemctl restart vnstat
Using vnStat to monitor monthly internet traffic on your Linux VPS helps you understand bandwidth usage, avoid unexpected overages, and identify abnormal traffic.
If you see unexpected usage after enabling vnStat, check for open services, review firewall rules, or open a support ticket with Evoxt for assistance.
For more Evoxt VPS guides, visit Evoxt Tutorials.