Lesson 6 | Determining How Interfaces Are Being Used |
Objective | Use the netstat command to view network interface statistics and interpret their meaning. |
netstat
for Network Interface Statistics
The netstat
command can be used to display a statistical summary of network interfaces on your system.
This provides valuable information about how data is being transmitted and received, as well as whether any
errors or drops are occurring. Monitoring these statistics is an important part of network administration and
troubleshooting.
netstat -i
Running netstat -i
shows the kernel interface table:
host$ netstat -i
Kernel Interface table
Iface MTU Met RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flags
lo 3584 0 28473 0 0 0 28473 0 0 0 BLRU
eth0 1500 0 844349 398 398 3 444986 0 0 0 BRU
netstat -i
command showing loopback (lo) and Ethernet (eth0) interfaces.
lo
for loopback, eth0
for Ethernet).U
=Up, B
=Broadcast, R
=Running, L
=Loopback.
These flags help confirm whether the interface is active and capable of sending/receiving traffic.
When reviewing interface statistics, focus on error and drop counts. A high number of
RX-ERR
or TX-ERR
values could point to faulty cabling,
driver problems, or a congested network. Consistent RX-DRP
or TX-DRP
values
may suggest buffer shortages. Monitoring these counters over time allows administrators to
detect and resolve network performance problems early.
Although netstat
remains available on many systems, modern Linux distributions
recommend using ip -s link
or the ss
command for more detailed
interface and socket statistics.
Test your understanding of interface statistics:
Take the Netstat Quiz