# Command line version of Speedtest



## balanga (Jan 15, 2018)

Is the anything like a command line version of Speedtest for measuring broadband speed?


----------



## tobik@ (Jan 15, 2018)

https://www.freshports.org/search.php?query=speedtest


----------



## Maelstorm (Jan 16, 2018)

A quick and dirty method might be something like this:

`time fetch ftp://ftp.gnu.org/gnu/gcc/gcc-7.2.0/gcc-7.2.0.tar.gz`

And then apply the formula:

`rate = size / time`

But fetch tells you what the rate is in realtime.


----------



## balanga (Jan 16, 2018)

tobik@ said:


> https://www.freshports.org/search.php?query=speedtest



In case anyone wants to try this you need to run `speedtest-cli`
Here's what I got...

```
Retrieving speedtest.net configuration...
Testing from Vectra Broadband (178.235.36.132)...
Retrieving speedtest.net server list...
Selecting best server based on ping...
Hosted by Telkab sp. z o.o. (Tczew) [46.48 km]: 34.278 ms
Testing download speed................................................................................
Download: 132.59 Mbit/s
Testing upload speed................................................................................................
Upload: 11.69 Mbit/s
```


----------

