vnstat
vnStat is a lightweight, console-based network traffic monitor that logs bandwidth usage per network interface for hours, days, months, and years. Unlike real-time monitors, vnStat runs as a background daemon and maintains a persistent database of traffic statistics, making it the go-to tool for long-term bandwidth tracking and historical analysis.
Key Features
- Persistent database — Stores hourly, daily, monthly, and yearly traffic statistics
- Low resource usage — Runs as a minimal daemon with negligible CPU and memory impact
- Multiple output formats — Terminal output, JSON, XML, and image export
- Traffic summary — Top 10 day/month summary for quick bandwidth overview
- Live display — Real-time traffic rate display with the –live option
- Custom queries — Query specific time ranges for detailed analysis
- Separate ingress/egress — Tracks received and transmitted data independently
- Interface grouping — Query traffic totals across multiple interfaces
Why Use It
vnStat is the definitive tool for long-term bandwidth accounting. While tools like iftop and nload show real-time rates, only vnStat keeps a persistent database that lets you answer questions like how much data was transferred last month or what the peak usage day was.
Use Cases
- Monthly bandwidth accounting — Track data usage for metered connections
- Usage trend analysis — Identify long-term bandwidth growth patterns
- Billing verification — Compare actual usage against ISP reported usage
- Historical troubleshooting — Check bandwidth levels during past incidents
Platform
Linux, macOS (via Homebrew), BSD
Licence
GNU General Public License v2.0
Website
humdi.net/vnstat
Views: 1