Here is practical way to do this;
nc is a golden linux tool which stands for netcat.
On the receiver side;
# nc -l 10.129.50.45 -p6666 > /dev/null
10.129.50.45 is the listened IP address.
On the transmitter side;
# dd if=/dev/zero bs=1024k count=1024 | nc 10.129.50.45 6666
At the end of pumping of the zeros "dd" shows total used time and bw/s values.
If not, you can use the "time" command before the dd to do this.