Linux Command-Line Bandwidth Speed Tests

Solution 1:

If you can't be bothered to install iperf (see qedi's answer), you could precede any command that shifts a known amount of data with the time command and do a sum.

Solution 2:

iperf is simple and easy to use.

It requires a client and server.

(on the server)

 user@server$ iperf -s

(on the client)

 user@client$ iperf -c server.domain
 ------------------------------------------------------------
 Client connecting to 192.168.1.1, TCP port 5001
 TCP window size: 16.0 KByte (default)
 ------------------------------------------------------------
 [  3] local 192.168.1.3 port 52143 connected with 192.168.1.1 port 5001
 [ ID] Interval       Transfer     Bandwidth
 [  3]  0.0-10.0 sec    113 MBytes  94.7 Mbits/sec