
Hello!
In today’s world, where high-speed Internet access is crucial, monitoring and optimizing network speeds is becoming increasingly important. In this tutorial, we’ll take a look at how to use the speedtest-cli tool on the popular Raspberry Pi to conduct an effective test of Internet access speed.
Learn how to quickly and easily install and configure this tool to get valuable information on the performance of your local network. Discover how to track download and upload speeds, which can be useful for monitoring your Internet connection.
What is speedtest-cli?
Speedtest-cli is a command line interface (CLI) tool for conducting Internet speed tests without using a browser GUI. It was created by Matt Martz, who is a software developer and an active member of the open source community. It is a simple, easy-to-use application that allows users to quickly and conveniently check the download speed, upload speed and latency of their Internet connection.
The speedtest-cli tool uses Speedtest.net, a popular platform for measuring Internet speeds. During the test, the tool establishes a connection to the nearest Speedtest.net server, uploads and downloads data, and then presents results such as download speed (download), upload speed (upload) and latency (ping).
Preparation
Before we start checking the speed of the Internet, it is a good idea to properly prepare our device – I will use Raspberry Pi version 4B for the tutorial. We will issue commands to our device via SSH.
- Currently, you can already use the commercially available Raspberry Pi 5, however, its availability is very low. I recommend using rpilocator.com to see where you can currently get a reasonably priced device;
- For Microsoft Windows operating system I recommend PuTTY, while for Apple macOS operating systems I recommend Termius.
Step 1 – Update package list and upload updates
- Launch PuTTY (Windows OS) or Termius (macOS), then connect to your device,
- Enter the following command to update the package list and install available updates:
sudo apt-get update && sudo apt-get upgrade -y
Step 2 – Install the speedtest-cli package
- Enter the following command to update the speed measurement package:
sudo apt-get install speedtest-cli -y
- Wait a short while until the package installation process is complete. Once successfully installed, you can move on to the next command you will execute on the command line.
How to measure internet speed with speedtest-cli on Raspberry Pi
- To check your internet speed, use the following command to launch the application:
speedtest-cli
- After entering the above command, you will receive a report of the measurement of the speed of your Internet connection in a short time. Below you will find an example of the measurement result:
Retrieving speedtest.net configuration...
Testing from YOUR ISP NAME (XXX.XXX.XXX.XXX)...
Retrieving speedtest.net server list...
Selecting best server based on ping...
Hosted by TOM MEDIA (Dabrowa Górnicza) [248.38 km]: 9.454 ms
Testing download speed................................................................................
Download: 527.30 Mbit/s
Testing upload speed......................................................................................................
Upload: 165.59 Mbit/s
In the above result, you can see the results of internet speed, taking into account both downloading and uploading data. If you prefer to display the output in bytes instead of bits, use the following command:
speedtest-cli --bytes
- After entering the above command, you will receive a report of the measurement of the speed of your Internet connection in a short time. Below you will find an example of the measurement result:
Retrieving speedtest.net configuration...
Testing from YOUR ISP NAME (XXX.XXX.XXX.XXX)...
Retrieving speedtest.net server list...
Selecting best server based on ping...
Hosted by KSU Provector (Gorzow Wielkopolski) [393.08 km]: 10.081 ms
Testing download speed................................................................................
Download: 66.01 Mbyte/s
Testing upload speed......................................................................................................
Upload: 20.38 Mbyte/s
Read also:
- Home Assistant: Install mirror lighting on ESPHome / Set up simple mirror lighting with ESPHome in Home Assistant. Discover simple integration and control light with ease.
- print(“Helllo World”) / Welcome to my blog, where ‘Hello World’ is the symbolic start. Discover with me the fascinating world of coding and news from the world of technology.
- Synology: Unblock web ports for Nginx Proxy Manager / Unblock ports on Synology and configure Nginx Proxy Manager. Przewodnik ułatwi instalację serwera proxy, zapewniając proste zarządzanie serwerem.
- ADS-B: Receiver Installation and Configuration on Raspberry Pi / Discover the secrets of installing and configuring your own ADS-B antenna on Raspberry Pi. Develop skills and track aircraft in real time.
- Traccar: A guide to installing on Synology with Docker / Step-by-step guide: Installing Traccar on Synology using Docker. Effective vehicle tracking on your own server.
- Traccar: Configuring GPS communication in Docker / Step by step how to enable Traccar GPS communication. Using Docker Compose, open ports for managing and receiving GPS data.
Comments (1)
Makssays:
31/07/2024 at 21:37Widać że polska i dzięki za pomoc w instalacji.