web-image-f23fe804058174dd4b4eabfde4bedd8bHave you ever wanted to check your Network throughput between your ESX Hosts? or even between VM’s? Well I needed to do this, and I couldn’t find any straight forward how-to’s.

Having been pointed in the direction of a simple application called IPerf by Simon Gallagher I opted to use the Windows version. I’m not great with Linux, and as this is an open source application, documentation is a little hard to come by. So for me, this post is also to remind me how on IPerf works should i need to use it again.

IPerf is a single .exe which you run from the Command Line. So to start with I would recommend downloading the .exe to C:\ to make life a little easier.

IPerf needs to be run on both the Source and Destination workstations for the tests to run. To do so;

  • Start -> Run -> “cmd”
  • Navigate to where IPerf.exe is located
  • To run the Server: iperf -s
  • To run the Client: iperf -c <server ipaddress>

Once you hit Enter on the Client PC, a basic 10 second bandwidth test is performed. (IP’s removed to protect the innocent.)

throughputclient1

IPerf has lots of extra options which you can used to vary the tests. A list of options can be found either at the bottom of this post or by typing iperf -h.

This is the test i used the most: iperf -c <Server IPAddress> -t 180 -r

Using -t 180 and -r switches, i ran a 3 minute test on both incoming and outgoing connections to make sure both were approximately the same.

The information provided was basic but sufficaint for my needs.

throughputclient

Here are the available switches:

C:\>iperf -h
Usage: iperf [-s|-c host] [options] iperf [-h|–help] [-v|–version]

Client/Server:
-f, –format ย  ย  ย  [kmKM] ย  ย  format to report: Kbits, Mbits, KBytes, MBytes
-i, –interval ย  # ย  ย  ย  ย  ย  ย  ย  seconds between periodic bandwidth reports
-l, –len ย  ย  ย  ย  ย  ย  #[KM] ย  ย  ย  length of buffer to read or write (default 8 KB)
-m, –print_mss ย  ย  ย  ย  ย  ย  ย  ย  ย  print TCP maximum segment size (MTU – TCP/IP header)
-o, –output ย  ย  ย  <filename> output the report or error message to this specified file
-p, –port ย  ย  ย  ย  ย  # ย  ย  ย  ย  ย  ย  ย  server port to listen on/connect to
-u, –udp ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  use UDP rather than TCP
-w, –window ย  ย  ย  #[KM] ย  ย  ย  TCP window size (socket buffer size)
-B, –bind ย  ย  ย  ย  ย  <host> ย  ย  bind to <host>, an interface or multicast address
-C, –compatibility ย  ย  ย  ย  ย  for use with older versions does not sent extra msgs
-M, –mss ย  ย  ย  ย  ย  ย  # ย  ย  ย  ย  ย  ย  ย  set TCP maximum segment size (MTU – 40 bytes)
-N, –nodelay ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  set TCP no delay, disabling Nagle’s Algorithm
-V, –IPv6Version ย  ย  ย  ย  ย  ย  ย  Set the domain to IPv6

Server specific:
-s, –server ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  run in server mode
-D, –daemon ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  run the server as a daemon
-R, –remove ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  remove service in win32

Client specific:
-b, –bandwidth #[KM] ย  ย  ย  for UDP, bandwidth to send at in bits/sec (default 1 Mbit/sec, implies -u)
-c, –client ย  ย  ย  <host> ย  ย  run in client mode, connecting to <host>
-d, –dualtest ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  Do a bidirectional test simultaneously
-n, –num ย  ย  ย  ย  ย  ย  #[KM] ย  ย  ย  number of bytes to transmit (instead of -t)
-r, –tradeoff ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  Do a bidirectional test individually
-t, –time ย  ย  ย  ย  ย  # ย  ย  ย  ย  ย  ย  ย  time in seconds to transmit for (default 10 secs)
-F, –fileinput <name> ย  ย  input the data to be transmitted from a file
-I, –stdin ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  input the data to be transmitted from stdin
-L, –listenport # ย  ย  ย  ย  ย  ย  port to recieve bidirectional tests back on
-P, –parallel ย  # ย  ย  ย  ย  ย  ย  ย  number of parallel client threads to run
-T, –ttl ย  ย  ย  ย  ย  ย  # ย  ย  ย  ย  ย  ย  ย  time-to-live, for multicast (default 1)

Miscellaneous:
-h, –help ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  print this message and quit
-v, –version ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  ย  print version information and quit

[KM] Indicates options that support a K or M suffix for kilo- or mega-

Posted by Simon Long on The SLOG.
Add The SLOG to your RSS Reader.
Follow Simon Long on Twitter.
Check out his profile on LinkedIn.