LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

vnstat

Console-based network traffic monitor

TLDR

Display traffic summary for all interfaces
$ vnstat
copy
Display traffic summary for a specific interface
$ vnstat -i [network_interface]
copy
Display live stats for a specific interface
$ vnstat -l -i [network_interface]
copy
Show hourly traffic statistics with bar graph
$ vnstat -hg
copy
Measure and show average traffic for 30 seconds
$ vnstat -tr 30
copy

SYNOPSIS

vnstat [options] [interface]

DESCRIPTION

vnstat is a console-based network traffic monitor that keeps a log of network traffic for selected interfaces. It uses kernel interface statistics for minimal resource usage.The daemon (vnstatd) runs in the background collecting data, while the vnstat command queries and displays the collected statistics. Data persists across reboots in a database.

PARAMETERS

-i, --iface _interface_

Select specific interface
-l, --live
Display live traffic statistics
-hg, --hoursgraph
Show hourly statistics as bar graph
-tr, --traffic _seconds_
Measure traffic for specified duration
-d, --days
Show daily statistics
-m, --months
Show monthly statistics
-t, --top
Show top traffic days
-s, --short
Use short output format
--json
Output in JSON format
--xml
Output in XML format

INSTALL

sudo apt install vnstat
copy
sudo dnf install vnstat
copy
sudo pacman -S vnstat
copy
sudo apk add vnstat
copy
sudo zypper install vnstat
copy
brew install vnstat
copy
nix profile install nixpkgs#vnstat
copy

CAVEATS

Requires vnstatd daemon to be running for data collection. Initial statistics require time to accumulate. Traffic counters may reset if the interface is reconfigured. Statistics are based on kernel counters, not packet inspection.

SEE ALSO

vnstatd(8), iftop(8), nethogs(8), nload(1)

Braincup
Open source brain training for math, memory and focus
Braincup mini-games
41 mini-games · Apache-2.0
No ads · No tracking
Play in browser
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid
276 stars
From the maker of Linux Command Library
Copied to clipboard
Braincup
Open source brain training for math, memory and focus. 41 mini-games, from mental arithmetic to Sudoku, N-Back and Solo Chess.
Apache-2.0 licensed · No ads · No tracking · No account
From the maker of Linux Command Library
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid