Skip to content

Yet another unofficial speedtest.net client cli interface

Notifications You must be signed in to change notification settings

volcan96/SpeedTest

 
 

Repository files navigation

Build Status

SpeedTest++

Yet another unofficial speedtest.net client cli interface.

It supports the new (undocumented) raw TCP protocol for better accuracy.

What is different than https://github.com/taganaka/SpeedTest? This fork adds output to a single line, making writing to a file easier.

Features

  1. Best server discovery based on speed and distance from you.

  2. Line type discovery to select the best test profile based on your line speed.

  3. Aggressive multi-threading program in order to saturate your bandwidth quickly.

  4. Test supported: Ping / Jitter / Download speed / Upload speed / Packet loss (UDP).

  5. Provide a URL to the speedtest.net share results image using option --share

  6. This is based on https://github.com/taganaka/SpeedTest and adds output to a single line, making writing to a file easier. See section on outputting to a file on MacOS.

Installation

Requirements

  1. A modern C++ compiler
  2. cmake
  3. libcurl
  4. libssl
  5. libxml2

On Mac OS X

$ brew install cmake
$ mkdir ~/cmake_build
$ cd ~/cmake_build
$ cmake -DCMAKE_BUILD_TYPE=Release  # you can also put options after -DCMAKE but no options works
$ make install

On Ubuntu/Debian

$ sudo apt-get install build-essential libcurl4-openssl-dev libxml2-dev libssl-dev cmake
$ cd cmake_build
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ make install

Usage

$ ./SpeedTest --help
SpeedTest++ version 1.8
Speedtest.net command line interface
Info: https://github.com/taganaka/SpeedTest
Author: Francesco Laurita <[email protected]>

Usage: ./SpeedTest  [--latency] [--quality] [--download] [--upload] [--share] [--help]
      [--test-server host:port] [--quality-server host:port] [--output verbose|text]
optional arguments:
  --help                      Show this message and exit
  --latency                   Perform latency test only
  --quality                   Perform quality test only. It includes latency test
  --download                  Perform download test only. It includes latency test
  --upload                    Perform upload test only. It includes latency test
  --share                     Generate and provide a URL to the speedtest.net share results image
  --test-server host:port     Run speed test against a specific server
  --quality-server host:port  Run line quality test against a specific server
  --output verbose|text       Set output type. Default: verbose
$

Outputting to a file on MacOS

# pre-reqs: install homebrew and moreutils (for timestamp formatting)
# homebrew install - # https://docs.brew.sh/Installation
$ mkdir homebrew && curl -L https://github.com/Homebrew/brew/tarball/master | tar xz --strip 1 -C homebrew
# moreutils install using homebrew. moreutils adds ts function allowing for flexible timestamps from command line
$ brew install moreutils 
# next command has 3 parts: 1) tells SpeedTest to run and output text 2) moreutils' ts to prepend a timestamp on Speedtest's output | writes/appends output to a file using tee (in this case to Google Drive
$ /usr/local/bin/SpeedTest --output text |  /usr/local/bin/ts '%Y-%m-%d %H:%M:%S,' | /usr/bin/tee -a /Users/chungus/Google\\ Drive/SpeedTestPlus.csv
# Pro Tip: Run the script on a schedule to save file to Google Drive. Then you can use Google Drive + BigQuery + Data Studio to create a fancy dashboard

License

SpeedTest++ is available as open source program under the terms of the MIT License.

About

Yet another unofficial speedtest.net client cli interface

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 86.9%
  • C 7.5%
  • CMake 4.3%
  • Dockerfile 1.3%