Measure your server's connection from the command line
HIZTESTI CLI measures download, upload, latency and connection quality without a browser. It reports in JSON, CSV or Prometheus format and is built to run in cron and monitoring systems.
What it does
To measure a server's connection you have to measure it from that machine. A browser test only tells you about the connection of the desktop you are sitting at; it says nothing about the line in your data centre. HIZTESTI CLI fills that gap: one command on the machine you are already connected to over SSH, and a result you can feed straight into other tools.
- Confirm a line has genuinely recovered after an outage
- Keep a record of the speed your provider committed to
- Measure a newly provisioned server before accepting it
- Track speed and latency over time on a Grafana dashboard
What it measures
| Measurement | What it means |
|---|---|
| Download / Upload | Data transferred per second (Mbps) |
| Latency (ping) | Round-trip time, with jitter, low and high values |
| Loaded latency | Latency while the line is saturated — this is what decides video calls and gaming |
| Bufferbloat | How much latency swells once the line fills up |
| RPM | RFC 9097 responsiveness: round trips per minute under load |
The measurement method is the same as the hiztesti.com web interface and has been published academically. Measuring the same line from the browser and the command line should give you comparable figures.
Install
Debian · Ubuntu
sudo apt-get install -y curl gpg
curl -fsSL https://packages.buildkite.com/netmetrik/hiztesti-deb/gpgkey \
| sudo gpg --dearmor -o /etc/apt/keyrings/netmetrik_hiztesti-archive-keyring.gpg
echo "deb [signed-by=/etc/apt/keyrings/netmetrik_hiztesti-archive-keyring.gpg] https://packages.buildkite.com/netmetrik/hiztesti-deb/any/ any main" \
| sudo tee /etc/apt/sources.list.d/hiztesti.list
sudo apt-get update && sudo apt-get install -y hiztestiRHEL · Rocky Linux · AlmaLinux · Fedora
sudo tee /etc/yum.repos.d/hiztesti.repo >/dev/null <<'EOF'
[hiztesti]
name=HIZTESTI CLI
baseurl=https://packages.buildkite.com/netmetrik/hiztesti-rpm/rpm_any/rpm_any/$basearch
enabled=1
repo_gpgcheck=1
gpgcheck=0
gpgkey=https://packages.buildkite.com/netmetrik/hiztesti-rpm/gpgkey
priority=1
EOF
sudo dnf install -y hiztestiBoth repositories are public — no authentication is required. Packages are signed and your package manager verifies the signature on every update. Once installed, new versions arrive through `apt upgrade` or `dnf upgrade`.
macOS · Linux (Homebrew)
brew tap netmetrik/hiztesti
brew install hiztestiOther systems
If you do not use a package manager, download the archive directly. Every release ships builds for Linux (x86_64 and ARM), macOS, FreeBSD and Windows.
curl -fsSL https://github.com/netmetrik/hiztesti-cli/releases/latest/download/hiztesti-linux-x86_64.tgz | tar xz
sudo install -m 755 hiztesti /usr/local/bin/Usage
hiztesti # measure and display
hiztesti -L # server list (id · city · country · capacity)
hiztesti -s 2 # measure against a specific server by id
hiztesti --simple # latency, download and upload only
hiztesti --no-share # do not submit the result, no link
hiztesti --help # all optionsServer selection is automatic by default: candidates are measured and the most suitable one is chosen. To pick one yourself, list them with `-L` and pass its id to `-s`. Ids are stable; server names can change.
Using it with monitoring systems
The CLI can report in machine-readable formats. Prometheus output can be written straight into node_exporter's textfile collector; in continuous mode it measures at the interval you set and appends one JSON record per line.
# node_exporter textfile collector (from cron)
hiztesti -f prometheus > /var/lib/node_exporter/hiztesti.prom
# continuous mode — every 15 minutes, one JSON record per line
hiztesti --interval 900 -f jsonl >> /var/log/hiztesti.jsonlWhen a measurement fails the Prometheus output does not stay silent: it reports `up=0` along with the reason. Otherwise the collector would keep reading the previous file and your dashboard would show everything as fine.
Each phase ends early once the measurement settles, which cuts data usage noticeably for an agent that runs on a schedule. Use `--full-duration` when you need fixed-length phases.
Exit codes
Exit codes are separated so that scripts can tell "no network" apart from "server is slow".
| Code | Meaning |
|---|---|
| 0 | Success |
| 2 | Usage error |
| 3 | Network unreachable |
| 4 | Download failed |
| 5 | Upload failed |
| 6 | Timeout |
| 130 | Interrupted |
Privacy
- When a test finishes the result is saved to a shareable page and you get a link. Run with --no-share to opt out.
- Command-line measurements are excluded from consumer statistics, ISP reports and published datasets.
- The CLI sends no location data.