vnstat
A console-based network traffic monitor.
vnstat keeps a long-running database of network interface usage by hour, day, month, and year. It does not capture packets; instead it polls the kernel's interface counters at intervals, which gives it negligible CPU and memory overhead. Reports can be plain text or rendered as small PNG charts.
The original implementation by Teemu Toivola dates back to 2002. The 2.x rewrite (2017) moved the database from text files to SQLite and added systemd integration, IPv6 support, and a JSON output mode for integration with monitoring tools.
vnstat is widely used to monitor data caps on metered links — mobile broadband, cellular tethering, and metered VPS instances — where users need to see "how much have I sent and received this month?" without running a full SNMP or Prometheus stack. Distribution packaging is broad and the daemon usually runs out of the box without configuration.
Install
Debian/Ubuntu: sudo apt install vnstat Fedora/RHEL: sudo dnf install vnstat Arch: sudo pacman -S vnstat
Authors
- Teemu Toivola