[raspberry-vi] Testing your internet connection speed from the command-line

  • From: Mike Ray <mike@xxxxxxxxxxxxxxx>
  • To: raspberry-vi@xxxxxxxxxxxxx
  • Date: Wed, 22 Jan 2014 18:35:08 +0000

Hello,

Here's a little utility I knocked up to test the speed of my connection.

First you need to install iperf:

(on Raspbian):
sudo apt-get install iperf

(on Arch):
sudo pacman -S iperf

And here's the script:

-- snip --
#!/bin/bash
# Test the speed of our internet connection.
# Results displayed in megabits/second

echo "Testing speed of internet connection..."
SPEED=$(iperf -f m -c iperf.scottlinux.com | grep 'Mbits' | sed -r 
's:.*Bytes\s+([0-9]+\.[0-9]+)\s+Mbits/sec:\1:')
echo "${SPEED} Megabits per second"
  -- snip --

I did this because tomorrow I am getting BT Infinity fibre-optic (did I 
mention that Mo?).

This evening my speed is around 0.48 Mbits/sec, pathetic.  Wet string 
would be faster.

Mike




-- 
Michael A. Ray
Analyst/Programmer
Witley, Surrey, South-east UK

I KEEP six honest serving-men, They taught me all I know. Their names are What 
and Why and When and How and Where and Who.
-- Rudyard Kipling (paraphrased)

Interested in accessibility on the Raspberry Pi?
Visit: http://www.raspberryvi.org/

 From where you can join our mailing list for visually-impaired Pi hackers

=========================================================== 
The raspberry-vi mailing list 
Archives: //www.freelists.org/archives/raspberry-vi
Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
-----------------------------------------------------------
Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi 
Foundation.

This list is not affiliated to the Raspberry Pi Foundation and the views and 
attitudes expressed by the subscribers to this list do not reflect those of the 
Foundation.

Mike Ray, list creator, January 2013

Other related posts: