In short, iperf can be installed on two machines within your network. You’ll run one as a server, and one as a client. On the server side, simply run:
On the client side, run:
The client side will try to shove TCP packets through the network interface as quickly as possible for a period of 10 seconds by default. Once that’s complete, you’ll see a report on the server and client that will look like this:
The previous test was run over an 802.11n network between a wired and wireless device. The typical downlink for an 802.11n network is about 40Mbit/s, so it’s obvious that my home network could use an adjustment.
You can also run bidirectional tests from the client either at the same time (
-d flag) or one after the other (
-r flag). The server side will keep running until you stop it, so you can leave it running and run tests from multiple locations over time. You can daemonize the server end if that makes things easier.
For the full list of options, refer to iperf’s man page.