zeldor.biz

Linux, programming and more

Copyright © 2025
Log in

Testing network with iperf

January 31, 2011 by Igor Drobot Leave a Comment

If you need to measure network throughput and capacity, I haven’t found a simpler solution than iperf. There isn’t much to say about the operation of iperf — it’s a very simple application in server/client mode.

In short, iperf can be installed on two machines within your network. You’ll run one as a server, and one as a client.

First we need to install iprerf (debian and ubuntu way):

1
aptitude install iperf

aptitude install iperf

Start iperf on server:

1
iperf -s

iperf -s

Start iperf on client:

1
iperf -c [server_ip]

iperf -c [server_ip]

The client side shove TCP packets through the network interface as quickly as it can for a period of only 10 seconds by default. Once that’s complete, you’ll see a report on the server and client that will look like this one:

1
2
3
4
5
6
7
8
id@crunch:~$ iperf -c 10.1.100.4
------------------------------------------------------------
Client connecting to 10.1.100.4, TCP port 5001
TCP window size: 16.0 KByte (default)
------------------------------------------------------------
[  3] local 172.16.0.5 port 57327 connected with 10.1.100.4 port 5001
[ ID] Interval       Transfer     Bandwidth
[  3]  0.0-10.0 sec  25.5 MBytes  21.4 Mbits/sec

id@crunch:~$ iperf -c 10.1.100.4 ------------------------------------------------------------ Client connecting to 10.1.100.4, TCP port 5001 TCP window size: 16.0 KByte (default) ------------------------------------------------------------ [ 3] local 172.16.0.5 port 57327 connected with 10.1.100.4 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 25.5 MBytes 21.4 Mbits/sec

In my case the client was started on my aspire one netbook and connected over my home WLAN.

-t flag can be used to set running time (default 10 seconds)

Filed Under: Linux, Networking Tagged With: iperf, network test, speed

Categories

Archives

Tags

apache2 Apple arduino ARM Automation backup bash Cisco Cluster Corosync Database Debian Debian squeeze DIY DNS Fedora FTP Fun Icinga Ipv6 KVM Linux LVM MAC OS X Monitoring MySQL Nagios Nginx openSUSE OpenVPN PHP Proxy Python python3 qemu RAID rsync Samba security ssh Ubuntu virtualization Windows Windows 7 Wordpress

Leave a Reply

Your email address will not be published. Required fields are marked *

Yeaaah Cookie! We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok