speedtest console Debian Ubuntu and CentOS
speedtest-cli is a fully open application to test our links, from the console, using a popular website speedtest.net. Use it to revise the servers available nearby, and during the test will be selected always the fastest. Once completed, you can test the results and can generate a URL to a page with a picture speedtest.net.
speedtest-cli needs to act Python Pip, the packet should be available on virtually any operating system. We will use the distribution Centos 7
Install package python-pip:
Centos7
1 | yum install python-pip |
Debian/Ubuntu:
1 | apt-get install python-pip |
Then instlaujemy package speedtest:
Centos:
1 | pip install speedtest-cli |
Debian/Ubuntu:
1 | pip install speedtest-cli |
If CentOS will return an error:
1 2 3 | Successfully installed speedtest-cli-1.0.7 You are using pip version 8.1.2, however version 9.0.1 is available. You should consider upgrading via the 'pip install --upgrade pip' command. |
Perform the upgrade command:
1 | pip install --upgrade pip |
Whole should work without problems.
Speedtest we command:
1 | speedtest |
We should get the result:
1 2 3 4 5 6 7 8 9 10 11 | [root@node ~]# speedtest Retrieving speedtest.net configuration... Testing from Hetzner Online GmbH (94.130.246.172)... Retrieving speedtest.net server list... Selecting best server based on ping... Hosted by Spacken.net (Hagen) [141.07 km]: 10.09 ms Testing download speed................................................................................ Download: 142.42 Mbit/s Testing upload speed................................................................................................ Upload: 65.65 Mbit/s |
If we want to get the result we graphical command:
1 | speedtest --share |
We then obtain the result with a link:
1 2 3 4 5 6 7 8 9 10 11 12 | speedtest --share Retrieving speedtest.net configuration... Testing from Hetzner Online GmbH (94.130.246.172)... Retrieving speedtest.net server list... Selecting best server based on ping... Hosted by Spacken.net (Hagen) [141.07 km]: 7.298 ms Testing download speed................................................................................ Download: 128.33 Mbit/s Testing upload speed................................................................................................ Upload: 66.53 Mbit/s Share results: http://www.speedtest.net/result/7040605661.png |
Graphic version is available at:
1 | Share results: http://www.speedtest.net/result/7040605661.png |
The result can be posted on the page or blog and presents itself as: