How to Install and Use SmokePing on Linux: Continuously Monitor RTT, Jitter, and Packet Loss

Monitoring tutorial - IT technology blog
Monitoring tutorial - IT technology blog

When the network “lags” but ping still works — a familiar problem for sysadmins

Familiar scenario: a user reports slow connectivity, you run ping 8.8.8.8, it comes back at 20ms, everything looks fine. But the user still complains about lag. The problem is that ping only tells you the state at that moment — it doesn’t reveal jitter (RTT variation), doesn’t detect sporadic packet loss, and doesn’t keep history for comparison over time.

I ran into this scenario repeatedly on a Prometheus + Grafana setup monitoring 15 servers. Prometheus with blackbox_exporter excels at scraping metrics on an interval, but for continuously tracking network quality in that “smoke rising every second” kind of way, SmokePing is the tool purpose-built for this problem — and this exact setup has caught issues before users reported them, more than once.

SmokePing sends bursts of pings continuously, plots RTT over time, uses color to represent jitter, and highlights packet loss events. Looking at a SmokePing graph, you can immediately see “the network was degraded from 2 AM to 4 AM” without having to dig through logs manually.

Installing SmokePing

On Ubuntu/Debian

SmokePing is available in the official repository — no PPA or source compilation needed:

sudo apt update
sudo apt install -y smokeping apache2 libapache2-mod-fcgid fping

During installation, it will ask about Exim/Postfix configuration for alert emails. If you don’t need this yet, select No configuration or Local only to skip.

On CentOS/RHEL 8+

# Enable EPEL repo first
sudo dnf install -y epel-release
sudo dnf install -y smokeping httpd fping

# Enable and start the service
sudo systemctl enable --now smokeping httpd

Check that the service is running:

sudo systemctl status smokeping
# Active: active (running) ✓

Configuring SmokePing in Detail

The main configuration file is located at /etc/smokeping/config (on Ubuntu). The structure is divided into 5 sections: General, Database, Presentation, Probes, and Targets.

Section General — basic information

*** General ***

owner    = SysAdmin
contact  = [email protected]
mailhost = localhost
sendmail = /usr/sbin/sendmail
imgcache = /var/lib/smokeping/imgcache
imgurl   = imgcache
datadir  = /var/lib/smokeping
piddir   = /var/run/smokeping
cgiurl   = http://your-server-ip/smokeping/smokeping.cgi
syslogfacility = local0

Section Probes — choosing a probe type

SmokePing supports multiple probe types: FPing (ICMP), Curl (HTTP latency), SSH, DNS. Using FPing by default is sufficient for most use cases:

*** Probes ***

+ FPing
binary = /usr/bin/fping
# Number of ping packets per measurement — more pings means a more accurate jitter graph
pings  = 20
# Interval between packets (ms)
mininterval = 11

pings = 20 means SmokePing sends 20 ICMP packets per measurement. From those 20 packets, it calculates min/avg/max RTT and packet loss. This value directly affects the accuracy of the jitter graph — bump it up to 20–30 if you need more detailed data.

Section Targets — defining hosts to monitor

This is the most important section. Targets are organized in a tree structure, grouping related hosts together:

*** Targets ***

probe = FPing

menu  = Top
title = Network Latency Monitor

+ Internet
menu  = Internet Uplinks
title = Internet Connectivity

++ Google_DNS
menu  = Google DNS (8.8.8.8)
title = Google DNS Latency
host  = 8.8.8.8

++ Cloudflare_DNS
menu  = Cloudflare DNS (1.1.1.1)
title = Cloudflare DNS Latency
host  = 1.1.1.1

++ ISP_Gateway
menu  = ISP Gateway
title = ISP Gateway Latency
host  = 203.113.xxx.xxx   # Replace with your ISP gateway IP

+ Internal
menu  = Internal Servers
title = Internal Network

++ AppServer
menu  = Application Server
title = App Server (192.168.1.10)
host  = 192.168.1.10

++ DBServer
menu  = Database Server
title = DB Server (192.168.1.20)
host  = 192.168.1.20

After editing the config, reload SmokePing to apply the new configuration:

sudo smokeping --check --config=/etc/smokeping/config
# If there are no syntax errors, reload:
sudo systemctl reload smokeping

Configuring Alerts for Packet Loss (Optional)

SmokePing can send an email when packet loss exceeds a threshold. Add the Alerts section to your config:

*** Alerts ***

to   = [email protected]
from = [email protected]

+packetloss
type    = loss
# Alert when loss > 20% in 2 consecutive measurements
pattern = >0%,>0%,>20%,>20%
comment = Packet loss detected on network!

Assign an alert to a specific target by adding the alerts line:

++ ISP_Gateway
menu   = ISP Gateway
title  = ISP Gateway Latency
host   = 203.113.xxx.xxx
alerts = packetloss

Checking and Monitoring via the Web Interface

Configuring Apache for Access

On Ubuntu, SmokePing automatically creates an Apache config file. Enable it:

sudo a2enconf smokeping
sudo a2enmod cgid
sudo systemctl reload apache2

Access it at: http://your-server-ip/smokeping/

To add Basic Auth to protect the interface from public access:

sudo htpasswd -c /etc/apache2/.htpasswd admin

# Add inside the <Directory> block in /etc/apache2/conf-available/smokeping.conf:
# AuthType Basic
# AuthName "SmokePing Monitoring"
# AuthUserFile /etc/apache2/.htpasswd
# Require valid-user

sudo systemctl reload apache2

Reading SmokePing Graphs

SmokePing graphs may look confusing at first, but become very intuitive once you’re familiar with them:

  • Center line (median line): average RTT — when this rises, latency is increasing
  • Blue shaded region (smoke): represents jitter — the wider the region, the more unstable the network
  • Red/orange dots: packet loss — more dots mean a higher packet loss rate
  • Darker center band: RTT p25–p75 (interquartile range) — the “core” of jitter

When the network is stable: the median line is flat, the smoke region is narrow, and there are no red dots. When something’s wrong: you see it immediately — the median spikes, the smoke widens, or red dots appear in clusters.

Verifying Data Collection

# View logs in real time
sudo journalctl -u smokeping -f

# Check whether RRD data files have been created
ls /var/lib/smokeping/Internet/
# You should see: Google_DNS.rrd  Cloudflare_DNS.rrd  ISP_Gateway.rrd

# SmokePing needs 5–10 minutes to collect enough data to render the first graph
# If the graph is empty, check that fping is working:
fping -c 5 8.8.8.8

What SmokePing Adds That Prometheus Doesn’t

If you’re running Prometheus + Grafana, SmokePing doesn’t replace it — it complements it: Prometheus tracks server metrics (CPU, RAM, disk I/O), while SmokePing specializes in network link quality — two different perspectives on the same system.

Here’s a moment where this setup saved me once: the system was reported as “slow” during peak hours, and Prometheus showed nothing unusual (CPU/RAM were both fine). Opening SmokePing, I immediately saw 15–20% packet loss from the server to the ISP gateway during that window — the problem was the network link, not the server. Calling the ISP with concrete data in hand got the ticket resolved much faster than just saying “the network is slow.”

If you want to pull SmokePing data into Grafana, you can use smokeping_prober — a dedicated Prometheus exporter for SmokePing. But for small teams, SmokePing’s built-in web interface is more than sufficient and easy to share with the team when debugging together.

Share: