We would like to preface this tutorial by clarifying that speedtest-cli is definitely not the most reliable tool for evaluating server connection speeds. By design, it's meant to test residential connections, and its test servers often share network ports that can be oversaturated (on their end) at certain times.
Additionally, there is a known bug in the default speedtest-cli package in CentOS/Fedora/Debian/Ubuntu repositories which can inaccurately report slow network speeds. This is due to a bug with the version published by the vendor, and does not represent any sort of network slowness with your RackNerd related service.
You can get around this issue by running speedtest-cli standalone, which usually yields better results.
To run speedtest-cli standalone, you need Python installed on your server, and then you can use the following commands:wget -O speedtest-cli https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py
chmod +x speedtest-cli
Please note that the geo-IP data of speedtest-cli might not accurately indicate the true physical location of your VPS. This discrepancy can cause speedtest-cli to default to a server based on incorrect location information when run without flags. If you prefer to use a specific server for the test, you'll need to manually select it:./speedtest-cli --list
Then, use the "./speedtest-cli --server ID" command to specify a server. For instance:./speedtest-cli --server 21541
However, keep in mind that not all speedtest-cli testing servers might be displayed/accessible at a given time due to issues like high test usage, maintenance, GEOIP factors, etc, on their end.
Alternative to Speedtest-Cli:
Given the inconsistencies in speedtest-cli, you might want to consider other methods for testing your server's network connection speed. iperf3 is a highly recommended tool, however, it often necessitates the configuration of another remote server for testing.
As a result, a simpler, widely-used alternative is the nws.sh script, which is a more comprehensive script that tests your server network speed using speedtest.net infrastructure. You can run the below on your server in order to run a nws.sh test:curl -sL nws.sh | bash -s -- -r na