Quick Linux Tip #101:
Question: A single TCP connection seems slow. Can I measure its real throughput?
Try: sudo iftop -i eth0 -nNP -f 'port 443'
Info: iftop acts as top for network bandwidth, tracking individual connections and displaying 2s/10s/40s moving averages to pinpoint bandwidth hogs.
Examples:
- $
sudo iftop -i eth0# Launch interactive mode without filters - $
sudo iftop -i eth0 -t -s 30# Output text mode summary for 30 seconds - $
sudo nload eth0# View interface-wide bandwidth graphs
Note: Install via sudo apt install iftop. Interactive controls: press s to toggle source ports, d for destination ports, and t to cycle through traffic display modes.
Leave a Reply