For checking the internet connection speed, there are a number of services available online. In fact, the number of such services is so high that it’s kind of confusing which one is more reliable. In that case, SpeedTest is the top choice for the majority. It’s because the service is reliable and consistent with hundreds of servers worldwide.
SpeedTest is also a favorite service that Linux server admins and enthusiasts admire. It allows you test your network speed, bandwidth and other info within a comfort of a website. As it’s a website service, you need to have access to a browser for checking the connection, right? When working with a remote client without any web browser access, it can be pain to enjoy SpeedTest service.
Don’t worry; SpeedTest is still available for using on the terminal! It’s Speedtest-cli – a command line utility that allows any users run SpeedTest right from the terminal.
Install Speedtest-cli
This tool greatly depends on Python. So, make sure that you have the latest version of Python installed in your system. Run the following commands according to your system for ensuring the availability of the latest Python version.
Get the latest version of Python.
After Python is successfully set in your system, run the following commands –
- Ubuntu
sudo apt install speedtest-cli
- Debian
sudo apt-get install speedtest-cli
- OpenSUSE
sudo zypper install speedtest-cli
- Fedora
sudo dnf install speedtest-cli -y
- Arch Linux
# Enable the "Community" repository by removing all the '#' from the "Community" section of "pacman.conf" sudo nano /etc/pacman.conf # Update local repository database sudo pacman -Syy # Install speedtest-cli sudo pacman -S speedtest-cli
- Generic instruction
The easiest way to install speedtest-cli is through the PIP tool of Python.
pip install speedtest-cli OR pip3 install speedtest-cli
Don’t use “sudo” with this command as it’ll mess up with the environment of Python.
Using speedtest-cli
Check out the current internet speed –
speedtest-cli
If you only need a simpler result output format, run this command –
speedtest-cli --simple
You can also check the speed of your “download” and “upload” speed separately.
speedtest-cli --no-download speedtest-cli --no-upload
For viewing graphical result, run the following command –
speedtest-cli --share --simple
Now, speedtest-cli uses “bits” to measure the internet speed. That’s the universal unit. However, if you prefer getting the results in “bytes”, then use the following command –
speedtest-cli --bytes
For exporting your data, you can also get the CSV format output.
speedtest-cli --csv
There are also a number of other available options to give you more in-depth result of your internet connection. Check all the available command arguments of speedteset-cli –
speedtest-cli --help
You can export the help texts as a document –
speedtest-cli --help >> ~/Documents/speedtest-cli-commands.txt
Voila! Speed test is now simpler, right?