ifstat
Monitor network interface traffic statistics
TLDR
View network interface statistics since last query
View network interface statistics since last boot
View error rate
SYNOPSIS
ifstat [ -i interface ] [ delay [ count ] ]
PARAMETERS
-i interface
Specifies the network interface to monitor. If not provided, ifstat monitors all network interfaces.
delay
Sets the delay in seconds between updates. The default is 1 second.
count
Specifies the number of updates to display before exiting. If not provided, ifstat runs indefinitely.
-t
Shows a timestamp with each output line.
-n
Resolves numerical address to hostnames.
-h
Displays help information.
-V
Displays the program version number.
DESCRIPTION
ifstat is a simple tool that reports network interface statistics, providing a real-time overview of network traffic. It displays the bandwidth used by all network interfaces or a selected subset. Unlike tools like `top` that show CPU and memory usage, ifstat focuses solely on network I/O, making it ideal for quickly identifying network bottlenecks or monitoring network activity.
It reads data from the kernel's network interface statistics and presents the data in an easily readable format. The output consists of two columns: incoming (rx) and outgoing (tx) traffic, typically in kilobytes per second (KB/s).
ifstat continues to update the display at a specified interval (defaulting to 1 second) until it's interrupted, making it useful for continuous monitoring. It is commonly used by system administrators and network engineers to observe network behavior, diagnose performance issues, and troubleshoot connectivity problems. Its simplicity and clear output make it an accessible tool for monitoring network activity on Linux systems.
UNITS
The output is typically displayed in kilobytes per second (KB/s). The units are automatically adjusted (KB/s, MB/s, GB/s, etc.) based on the amount of traffic.
INTERRUPTING IFSTAT
You can stop ifstat by pressing Ctrl+C.