Comments on Check Internet Speed with speedtest-cli on Debian and Ubuntu

This tutorial shows you how to test the network connection speed of Debian and Ubuntu desktop and server systems by using the speedtest-cli tool.

15 Comment(s)

Add comment

Please register in our forum first to comment.

Comments

By: tpeterson

Thanks for this tutorial, but running "speedtest_cli.py" in a terminal did not work for me. After researching this a bit, I found that simply running "speedtest-cli" works flawlessly. Love that I can run a speed test in a terminal!

By: till

Thank you for the notice. The command was differently indeed depending on the installation method. I've updated the tutorial so that the command is the same when you install it with pip or manually.

By: Luis M. Prous

There is a little error in the pip upgrade method... it says "-upgrade" and it must be "--upgrade" at the end of the line.

By: Jan Fikar

to share the image, you need the switch --share

By: bhimraya ssjjan

Thanks for this tutorial, speedtest_cli.py its working fine,but its shows diffrent result compare to browser speed test   

By: aid85

Is there a way to print out also time and date ?

By: Daniel

Timestamps would be extremely useful on this. Doing the crontab as mentioned above but adding the command date to it. - Looking like this at the moment with more work to do.

date >> /tmp/speedlog.txt; /usr/local/bin/speedtest-cli --simple >> /tmp/speedlog.txt

By: JJussi

I collect results (all servers at Helsinki, Finland) directly to the mongodb database, using ssh...

0 * * * * for addr in $(speedtest-cli --list|grep Helsinki|cut -d')' -f1 2> /dev/null); do ( ssh mongodb.domain.com "mongo --eval='db.getSiblingDB(\"network\").speed.insert($(speedtest-cli --server $addr --json))'" ) > /dev/null 2>&1 ; sleep 360; done

From there I can aggregate result of upload/download min, max, avg for every servers distinctly. ;-)

Next I should make some graphics with python, so I can see how speed variates during days...

By: Ryan Lewis

I need help doing the same thing to my script, can you steer me right, so i dont screw up my server?

 

By: Sjaak Pammers

Why would you go through all this trouble when you can just 'apt install speedtest-cli'? 

By: Spongman

this is a great article, but i'm afraid it's very bad advice. speedtest-cli is completely broken, reports wildly innacurate results, and the developer 'sivel' on GitHub has resolutely refused to address any of the dozens of issues filed on GitHub about this issue, immediately closing and locking these issues without comment.

By: photogrammer

the results are consitently 1/3 of what they should be vs the speedtest website

By: Rahul Kale

Nice article! keep posting.

By: Victor

You can test to specific server id,

I use http://www.speedtestserver.com/ to find the id of server.

 

By: jerrybuntu

Super article

Changed pip by pip3 - but the rest works great!

It also explains why Ubuntu 20.04 gives wrong download speeds (system monitor and adm).

Thanks!