Deploy option 1: Tracerlight only
The simplest deployment. Tracerlight servers and clients run as services, and every instance writes JSON lines to its own log file in a log directory on its host. Your own log shipper reads those files and sends them to the platform you already use for storage, graphs and analysis. One host can run many servers and many clients.
WhenArchitectureQuestionsNames and tagsPortsLinuxFreeBSDOpenBSDWindowsAdd or removeLog filesFor your log shipperRecordsVerifyTroubleshootingUpgradeTest status
Applies to Tracerlight 2.22.1-f136bd5. Download and verify the binary first: Install Tracerlight, section 1. No Gyroscopic or Tailfin is involved.
1. When to choose it
- Choose it when you already run a log or metrics platform and a log shipper, and want the Tracerlight measurements there. SolidFokus itself stores and graphs nothing in this option.
- Choose option 2 when you want SolidFokus dashboards or MCP access for an AI assistant: full stack over HTTP. Built-in TLS without NGINX is option 3 (coming).
2. Architecture
host A host B
tracerlight-client-cli-a-srv1 --UDP 9000-9031--> tracerlight-server-srv1
tracerlight-client-cli-a-srv2 --UDP 9100-9131--> tracerlight-server-srv2
| |
v v
/var/log/solidfokus/ /var/log/solidfokus/
tracerlight-client-cli-a-srv1.log tracerlight-server-srv1.log
tracerlight-client-cli-a-srv2.log tracerlight-server-srv2.log
| |
+------> your log shipper ---> your backend <----+
Clients send UDP packets to a server's port range and measure loss and round-trip time. Each instance writes its stats records and its operational log, as JSON lines, to one file. Your own log shipper reads these files and sends them to your backend.
3. Operator questions
An AI agent should get these answers before it changes anything:
- Which hosts run Tracerlight, and which OS does each run (Linux glibc/musl with systemd, FreeBSD, OpenBSD 7.9 and 8.0, Windows)?
- Which servers run on each host? Give each a tag (rules), unique across the whole deployment.
- Which client tests which server? Each client→server pair is one client instance on the client host, tag
<client-name>-<server-tag>. - Port range per server: base port and sessions (rule). Rate per session (default 32 pps) and stats interval (default 1 s).
- The shared key (
-k), a decimal integer from 0 to 18446744073709551615 (64-bit unsigned); hex or other text fails at start. Generate one, for example withod -An -N8 -tu8 /dev/urandom | tr -d ' '(Windows PowerShell:$b = New-Object byte[] 8; [Security.Cryptography.RandomNumberGenerator]::Create().GetBytes($b); [BitConverter]::ToUInt64($b, 0)), and tell the operator where it is stored. - The log directory, if not the default (
/var/log/solidfokus, Windows%ProgramData%\solidfokus\logs), and which account your log shipper runs as, so it can be given read access. - Firewall tooling on each server host (iptables, firewalld, pf, Windows Firewall).
4. Names, tags and per-instance arguments
Every instance has a tag (-t/--tag), and its service name and log file name contain the role and the tag, so the name, the file and the records always agree. The service layer adds --server (servers only), --tag, --output json and --log-format json itself; the per-instance arguments hold everything else and must not repeat them.
- Tag rule: lowercase letters, digits and
-, 1–64 characters, not starting or ending with-, no_:^[a-z0-9]([a-z0-9-]{0,62}[a-z0-9])?$. This is stricter than what Tracerlight accepts, so that the BSD names below can be turned back into the tag, and Windows service names (case-insensitive) cannot collide. - Server tag: the server's own name, for example
srv1. One server instance serves many clients. - Client tag:
<client-name>-<server-tag>, for examplecli-a-srv1. One client instance tests exactly one server. - Log file:
tracerlight-<role>-<tag>.log, roleserverorclient. - Key:
-k <KEY>in the per-instance arguments is a numeric validation key, a decimal integer from 0 to 18446744073709551615 (64-bit unsigned), the same on a server and every client that tests it. A hex or text key fails at start withinvalid digit found in string. Generate one withod -An -N8 -tu8 /dev/urandom | tr -d ' '.
| Linux (systemd) | FreeBSD | OpenBSD | Windows | |
|---|---|---|---|---|
| Instance | tracerlight-server@srv1, tracerlight-client@cli-a-srv1 | instance server_srv1, client_cli_a_srv1 of the script tracerlight | script tracerlight_server_srv1, tracerlight_client_cli_a_srv1 | service tracerlight-server-srv1, tracerlight-client-cli-a-srv1 |
| Arguments | /etc/tracerlight/<role>-<tag>.conf | tracerlight_<id>_args in rc.conf | rcctl set <name> flags "…" | the --install-service command line |
| Log file | /var/log/solidfokus/tracerlight-<role>-<tag>.log | %ProgramData%\solidfokus\logs\tracerlight-<role>-<tag>.log | ||
BSD names can contain only letters, digits and _, so they write each - of the tag as _; the scripts turn it back (cli_a_srv1 → cli-a-srv1) for the tag and the log file name.
5. Ports
- A server binds every port of
-p…-p+-n−1, all or nothing; if one port is taken it exits withError: failed to bind …. Server ranges on one host must not overlap (0.0.0.0overlaps every address on the host). - Rule: server instance k on a host (k = 0, 1, 2 …) uses
-p 9000+100kwith-nat most 100: 9000, 9100, 9200 … At most 10 server instances per host (9000–9999). - Clients bind ephemeral local ports and need no port plan. Set a client's
-pto the server's base port; its-nis how many sessions it runs and does not need to match the server's-n. The client probes-p, learns the server's port range, and spreads its sessions across those ports. - Ephemeral (client) ports: Linux 32768–60999 and Windows 49152–65535 by default, and FreeBSD from 10000, all above 9999. On OpenBSD the default ephemeral range starts at 1024 and overlaps the server ports 9000–9999, so a client or other software on the same host can occasionally take a server port; the server then fails to start with
Address in use. Resolving that, by port choice or host settings, is up to the operator. Starting the servers before the clients keeps that host's Tracerlight clients off the server ports at start-up; it does not cover other software or a server restarted later. - Open one inbound UDP rule per server range (examples in Install Tracerlight, section 4).
Worked example, host alpha with two servers and three clients:
| Instance | Arguments (without the ones the service adds) | Firewall |
|---|---|---|
server alpha1 (k=0) | -k <KEY> -p 9000 -n 32 0.0.0.0 | in UDP 9000–9031 |
server alpha2 (k=1) | -k <KEY> -p 9100 -n 64 0.0.0.0 | in UDP 9100–9163 |
client alpha-beta1 | -k <KEY> -p 9000 -n 32 -r 32 beta.example.net | out UDP 9000–9031 to beta |
client alpha-gamma1 | -k <KEY> -p 9000 -n 32 -r 32 gamma.example.net | out UDP 9000–9031 to gamma |
client alpha-gamma2 | -k <KEY> -p 9100 -n 16 -r 32 gamma.example.net | out UDP 9100–9115 to gamma |
6. Set up the instances
Install the binary as /usr/local/bin/tracerlight (Windows: C:\Program Files\SolidFokus\tracerlight.exe) as in Install Tracerlight, section 1. Keep --duration, --packets and --config out of the service arguments.
Linux (systemd)
Linux is covered with systemd only for now (systemd 240 or newer; hosts without systemd, such as Alpine with OpenRC, are not covered yet). Two template units serve any number of instances; each instance reads its arguments from its own file. The units send both streams to the instance's log file with append:. If you prefer journald, use the units on the install page (StandardOutput=journal) instead; this page covers the log directory only.
/etc/systemd/system/tracerlight-server@.service:
[Unit]
Description=Tracerlight server %i
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User=tracerlight
Group=tracerlight
EnvironmentFile=/etc/tracerlight/server-%i.conf
ExecStart=/usr/local/bin/tracerlight --server --tag %i --output json --log-format json $TRACERLIGHT_ARGS
Restart=on-failure
RestartSec=5
StandardOutput=append:/var/log/solidfokus/tracerlight-server-%i.log
StandardError=append:/var/log/solidfokus/tracerlight-server-%i.log
SyslogIdentifier=tracerlight-server-%i
NoNewPrivileges=true
ProtectSystem=strict
ProtectHome=true
PrivateTmp=true
[Install]
WantedBy=multi-user.target
/etc/systemd/system/tracerlight-client@.service:
[Unit]
Description=Tracerlight client %i
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User=tracerlight
Group=tracerlight
EnvironmentFile=/etc/tracerlight/client-%i.conf
ExecStart=/usr/local/bin/tracerlight --tag %i --output json --log-format json $TRACERLIGHT_ARGS
Restart=on-failure
RestartSec=5
StandardOutput=append:/var/log/solidfokus/tracerlight-client-%i.log
StandardError=append:/var/log/solidfokus/tracerlight-client-%i.log
SyslogIdentifier=tracerlight-client-%i
NoNewPrivileges=true
ProtectSystem=strict
ProtectHome=true
PrivateTmp=true
[Install]
WantedBy=multi-user.target
Use %i as above, not %I: %I would turn each - of a tag into /.
id tracerlight || useradd --system --no-create-home --shell /usr/sbin/nologin tracerlight
install -d -m 0755 -o root -g root /var/log/solidfokus
mkdir -p /etc/tracerlight
chown root:tracerlight /etc/tracerlight; chmod 0750 /etc/tracerlight # the service user must reach option 2's post-config
# One arguments file per instance, readable by root only (it holds the key)
umask 077
echo 'TRACERLIGHT_ARGS="-k <KEY> -p 9000 -n 32 0.0.0.0"' > /etc/tracerlight/server-srv1.conf
echo 'TRACERLIGHT_ARGS="-k <KEY> -p 9000 -n 32 -r 32 srv1.example.net"' > /etc/tracerlight/client-cli-a-srv1.conf
systemctl daemon-reload
systemctl enable --now tracerlight-server@srv1
systemctl enable --now tracerlight-client@cli-a-srv1
systemctl status 'tracerlight-*@*'
ls -l /var/log/solidfokus/
Log level for one instance: add a line RUST_LOG=debug to its arguments file and restart it. Rotation, /etc/logrotate.d/solidfokus-tracerlight:
/var/log/solidfokus/tracerlight-*.log {
daily
rotate 7
copytruncate
compress
delaycompress
missingok
notifempty
}
copytruncate copies the file and then empties it in place, so Tracerlight keeps writing without a restart. A line written between the copy and the truncation can be lost; that is the documented trade-off of copytruncate. Keep copytruncate: SIGHUP does not reopen Tracerlight's log. From 2.22.0 a service (neither stdout nor stderr is a terminal) ignores SIGHUP, so a postrotate kill -HUP no longer stops the process, and it also does not reopen the file. A foreground run whose stdout or stderr is a terminal treats SIGHUP as a graceful stop.
Tested on Ubuntu 24.04 (2026-11-26) with 2.22.0-a507b62: the template units with %i in the append: path (servers and clients on one host, measuring other hosts), start at boot, adding and removing an instance, the logrotate file (forced run) and an upgrade with restart. The log file systemd creates is owned by root, mode 0644 (checked 2026-11-26).
FreeBSD (rc.d)
One script runs every instance on the host, listed in tracerlight_instances; an instance id is <role>_<tag with - written as _>. Each instance runs under its own daemon(8) supervisor, which restarts it after a crash and reopens the log file when newsyslog rotates it. The script refuses arguments that set --server, --tag, --output or --log-format. It does not use $0, because rc(8) sources the script at boot.
/usr/local/etc/rc.d/tracerlight (mode 0555, owner root):
#!/bin/sh
#
# PROVIDE: tracerlight
# REQUIRE: LOGIN
# KEYWORD: shutdown
#
# Multi-instance Tracerlight (Tracerlight-only deployment). One script,
# many instances (the "profiles" idiom of FreeBSD ports). rc.conf(5):
# tracerlight_enable="YES"
# tracerlight_instances="server_srv1 client_cli_a_srv1"
# instance id = <role>_<tag with "-" written as "_">, role server|client
# tracerlight_<id>_args="..." required; NOT --server/--tag/--output/--log-format
# tracerlight_runas="tracerlight" tracerlight_umask="022"
# Per instance: log /var/log/solidfokus/tracerlight-<role>-<tag>.log,
# pid file /var/run/tracerlight-<role>-<tag>.pid (daemon(8) supervisor).
# $0 is /etc/rc at boot (rc(8) sources this file), so the loop below calls
# the script by its absolute path, never by $0.
. /etc/rc.subr
name="tracerlight"
rcvar="tracerlight_enable"
load_rc_config $name
unset tracerlight_user tracerlight_flags
: ${tracerlight_enable:="NO"}
: ${tracerlight_runas:="tracerlight"}
: ${tracerlight_umask:="022"}
: ${tracerlight_instances:=""}
_script=/usr/local/etc/rc.d/tracerlight
if [ -z "$2" ]; then
[ -n "${tracerlight_instances}" ] || err 1 "tracerlight_instances is not set in rc.conf"
_rc=0
for _i in ${tracerlight_instances}; do
echo "===> tracerlight instance: ${_i}"
${_script} "$1" "${_i}" || _rc=1
done
exit ${_rc}
fi
_id="$2"
case " ${tracerlight_instances} " in
*" ${_id} "*) ;;
*) err 1 "instance ${_id} is not in tracerlight_instances" ;;
esac
case "${_id}" in
server_?*) _role=server; _roleflag="--server" ;;
client_?*) _role=client; _roleflag="" ;;
*) err 1 "instance ${_id}: must start with server_ or client_" ;;
esac
_tag=$(echo "${_id#*_}" | tr _ -)
eval _args=\"\${tracerlight_${_id}_args-}\"
_log="/var/log/solidfokus/tracerlight-${_role}-${_tag}.log"
pidfile="/var/run/tracerlight-${_role}-${_tag}.pid"
procname="/usr/sbin/daemon"
command="/usr/sbin/daemon"
command_args="-r -f -P ${pidfile} -H -m 3 -o ${_log} -M 0640 -u ${tracerlight_runas} /usr/local/bin/tracerlight ${_roleflag} --tag ${_tag} --output json --log-format json ${_args}"
required_files="/usr/local/bin/tracerlight"
start_precmd="tracerlight_prestart"
tracerlight_prestart()
{
[ -n "${_args}" ] || err 1 "tracerlight_${_id}_args is not set in rc.conf"
case " ${_args} " in
*" -s "*|*" --server "*|*" -t "*|*" --tag "*|*" --tag="*|*" -o "*|*" --output"*|*" --log-format"*)
err 1 "tracerlight_${_id}_args must not set --server, --tag, --output or --log-format" ;;
esac
install -d -m 0755 -o root -g wheel /var/log/solidfokus
# Owned by the service user from the start so a shipper in group
# tracerlight can read it before the first newsyslog rotation.
[ -f "${_log}" ] || install -m 0640 -o "${tracerlight_runas}" -g "${tracerlight_runas}" /dev/null "${_log}"
}
run_rc_command "$1"
id tracerlight || pw useradd tracerlight -c "Tracerlight" -d /nonexistent -s /usr/sbin/nologin
install -m 0555 tracerlight.rc /usr/local/etc/rc.d/tracerlight
sysrc tracerlight_enable=YES
sysrc tracerlight_instances="server_srv1 client_cli_a_srv1"
sysrc tracerlight_server_srv1_args="-k <KEY> -p 9000 -n 32 0.0.0.0"
sysrc tracerlight_client_cli_a_srv1_args="-k <KEY> -p 9000 -n 32 -r 32 srv1.example.net"
service tracerlight start # all instances
service tracerlight status client_cli_a_srv1 # one instance
ls -l /var/log/solidfokus/
Rotation: append one line per instance to /usr/local/etc/newsyslog.conf.d/solidfokus.conf (shared by the SolidFokus apps; never replace it). newsyslog sends SIGHUP to the daemon(8) supervisor named by the pid file, which reopens the log; Tracerlight itself never gets the signal.
# logfilename [owner:group] mode count size when flags [/pid_file]
/var/log/solidfokus/tracerlight-server-srv1.log tracerlight:tracerlight 640 7 * @T00 ZB /var/run/tracerlight-server-srv1.pid
/var/log/solidfokus/tracerlight-client-cli-a-srv1.log tracerlight:tracerlight 640 7 * @T00 ZB /var/run/tracerlight-client-cli-a-srv1.pid
-M 0640 needs FreeBSD 14.5, 15.1 or later. On 13.x, 14.0–14.4 and 15.0 remove -M 0640 from command_args; the script creates the file with mode 0640 before the first start anyway.
Tested on FreeBSD 15.1 (2026-11-23) with 2.22.0-a507b62, one server host and one client host: this script (start, stop and status of one and of all instances), and adding and removing the per-instance newsyslog lines. Tested again on FreeBSD 15.1 (2026-11-26): adding and removing an instance, a forced newsyslog rotation, an upgrade with restart, and start at boot.
OpenBSD (rc.d)
One copy of the instance script per instance, named /etc/rc.d/tracerlight_<role>_<tag with - written as _>. rc.subr takes the instance name from the file name; the script reads the role and the tag from it. Set the remaining arguments with rcctl set … flags.
Instance script, saved as tracerlight-instance:
#!/bin/ksh
#
# Instance script: install a copy per instance as
# /etc/rc.d/tracerlight_<role>_<tag with "-" written as "_">
# e.g. tracerlight_server_srv1, tracerlight_client_cli_a_srv1
# (rcctl names allow only letters, digits and "_").
# The role, the tag and the log name come from the script name.
# Set the other flags with: rcctl set <name> flags "..." (required;
# not -s/--server, -t/--tag, -o/--output or --log-format: added here)
daemon="/usr/local/bin/tracerlight"
daemon_flags=""
daemon_user="_tracerlight"
. /etc/rc.d/rc.subr
_rest=${_name#tracerlight_}
_role=${_rest%%_*}
_tag=$(print -r -- "${_rest#*_}" | tr _ -)
case ${_role} in
server) _fixed="--server --tag ${_tag} --output json --log-format json" ;;
client) _fixed="--tag ${_tag} --output json --log-format json" ;;
*) print -u2 "${_name}: name must be tracerlight_server_<tag> or tracerlight_client_<tag>"; exit 1 ;;
esac
pexp="${daemon} ${_fixed}${daemon_flags:+ ${daemon_flags}}"
rc_bg=YES
rc_reload=NO
_log="/var/log/solidfokus/tracerlight-${_role}-${_tag}.log"
rc_pre() {
[ -n "${daemon_flags}" ] || { print -u2 "${_name}: set the flags first: rcctl set ${_name} flags \"...\""; return 1; }
case " ${daemon_flags} " in
*" -s "*|*" --server "*|*" -t "*|*" --tag "*|*" --tag="*|*" -o "*|*" --output"*|*" --log-format"*)
print -u2 "${_name}: flags must not set --server, --tag, --output or --log-format"; return 1 ;;
esac
install -d -m 0755 -o root -g wheel /var/log/solidfokus
[ -f "${_log}" ] ||
install -m 0640 -o "${daemon_user}" -g "${daemon_user}" /dev/null "${_log}"
}
rc_start() {
rc_exec "${pexp} >>${_log} 2>&1"
}
rc_cmd $1
id _tracerlight || { groupadd _tracerlight; useradd -c "Tracerlight Daemon" -d /nonexistent -g _tracerlight -s /sbin/nologin _tracerlight; }
install -d -m 0755 -o root -g wheel /var/log/solidfokus
install -m 0555 tracerlight-instance /etc/rc.d/tracerlight_server_srv1
install -m 0555 tracerlight-instance /etc/rc.d/tracerlight_client_cli_a_srv1
rcctl enable tracerlight_server_srv1
rcctl set tracerlight_server_srv1 flags "-k <KEY> -p 9000 -n 32 0.0.0.0"
rcctl enable tracerlight_client_cli_a_srv1
rcctl set tracerlight_client_cli_a_srv1 flags "-k <KEY> -p 9000 -n 32 -r 32 srv1.example.net"
rcctl start tracerlight_server_srv1 tracerlight_client_cli_a_srv1
rcctl check tracerlight_server_srv1 tracerlight_client_cli_a_srv1
Rotation: newsyslog reads only /etc/newsyslog.conf. A shell redirection cannot be reopened, so newsyslog renames the file, creates a new one and restarts the instance: a gap of a few seconds (up to about 15 s if the telemetry endpoint is unreachable) once a day, and the instance's counters start again from zero.
# logfilename owner:group mode count size when flags command
/var/log/solidfokus/tracerlight-server-srv1.log _tracerlight:_tracerlight 640 7 * @T00 ZB "/usr/sbin/rcctl restart tracerlight_server_srv1"
/var/log/solidfokus/tracerlight-client-cli-a-srv1.log _tracerlight:_tracerlight 640 7 * @T00 ZB "/usr/sbin/rcctl restart tracerlight_client_cli_a_srv1"
Tested on OpenBSD 8.0 (2026-11-26) with 2.22.0-a507b62: the instance script and its names with rcctl (enable, set flags, start, check, stop), start at boot, adding and removing an instance, and an upgrade with restart. Tested on OpenBSD 7.9 and 8.0 (2026-11-27) with 2.22.1-f136bd5: these newsyslog lines as printed, for a server and two clients (one added as in Add or remove an instance), with a forced rotation: the file renamed and gzipped, a new file _tracerlight:_tracerlight 0640, the restart through the quoted command, and counters starting again from zero. Not yet tested: a scheduled midnight (@T00) run by cron.
Windows (native service)
One service per instance, named tracerlight-<role>-<tag>. As a service, Tracerlight writes stats and logs to %ProgramData%\solidfokus\logs\<service name>.log itself, so the file name follows the scheme with no --log-file. Each service runs as its own virtual account. Elevated PowerShell:
$exe = "C:\Program Files\SolidFokus\tracerlight.exe"
& $exe -s -t srv1 -o json --log-format json -k <KEY> -p 9000 -n 32 0.0.0.0 --install-service tracerlight-server-srv1
New-NetFirewallRule -DisplayName "Tracerlight server srv1 UDP 9000-9031" -Direction Inbound -Protocol UDP -LocalPort 9000-9031 -Action Allow
Start-Service tracerlight-server-srv1
& $exe -t cli-a-srv1 -o json --log-format json -k <KEY> -p 9000 -n 32 -r 32 srv1.example.net --install-service tracerlight-client-cli-a-srv1
Start-Service tracerlight-client-cli-a-srv1
Get-Service tracerlight-*
Get-ChildItem "$env:ProgramData\solidfokus\logs\tracerlight-*.log"
# Read access for your log shipper's account; run again after every --install-service
icacls "$env:ProgramData\solidfokus\logs" /grant "<SHIPPER ACCOUNT>:(OI)(CI)RX"
Keep -s (servers only), -t <tag>, -o json and --log-format json on every install line and make the service name match them; Tracerlight does not check that. --install-service replaces the permission list of the log directory, which removes access you granted earlier. Rotation is built in: above 10 MiB the file is renamed to .1 (up to .5), checked every 30 s, with no restart. To change an instance's arguments, run --uninstall-service <name> and install it again. More on Windows services: Install Tracerlight, section 5.
Tested on Windows Server 2022 (2026-11-26) with 2.22.0-a507b62: a server and a client service with these names on one host (install, firewall rule, start), measuring a remote server. Not yet tested on a real host: the log file names, the icacls read grant for a log shipper, and rotation while another process has the file open.
Add or remove an instance
- Pick the tag (rules) and, for a server, the next free port block (rule).
- Linux: write
/etc/tracerlight/<role>-<tag>.conf, thensystemctl enable --now tracerlight-<role>@<tag>. Remove:systemctl disable --now …and delete the file. - FreeBSD: add the id to
tracerlight_instances, settracerlight_<id>_args, add the newsyslog line,service tracerlight start <id>. Remove:service tracerlight stop <id>first, then the id, the args (sysrc -x) and the newsyslog line. - OpenBSD: copy the script to the new name,
rcctl enable,rcctl set … flags, add the newsyslog line,rcctl start. Remove:rcctl stop,rcctl disable, delete the script and the newsyslog line. - Windows:
--install-service, theicaclsgrant again,Start-Service. Remove:--uninstall-service <name>; the log files are kept. - Servers: open or close the firewall rule for the range.
- Check as in Verify. Old log files stay until you delete them.
Checklist per host (for an AI agent)
tracerlight -Vprintstracerlight 2.22.1-f136bd5.- Every planned instance is running:
systemctl status 'tracerlight-*@*',service tracerlight status,rcctl check <name> …orGet-Service tracerlight-*. ls -l <logdir>shows onetracerlight-<role>-<tag>.logper instance, and each grows once per interval.tail -n 1 <file> | jq -r .eventprintsstats, andjq -r 'select(.event) | .tag' <file> | sort -uprints exactly the tag in the file name.- Client files:
lostdoes not keep rising, andrtt_avg_nsis not 0 in recent records. - Your log shipper's account can read the files (owners).
7. Log files
| OS | Log directory | File name | Owner / mode | Rotation |
|---|---|---|---|---|
| Linux (systemd) | /var/log/solidfokus (root, 0755) | tracerlight-<role>-<tag>.log | created by systemd as root; expected 0644 (not yet tested on a real host) | logrotate: daily, 7 kept, copytruncate, compressed (.log.1, .log.2.gz …, or dated names if your logrotate.conf sets dateext) |
| FreeBSD | /var/log/solidfokus (root:wheel, 0755) | same | tracerlight:tracerlight 0640 | newsyslog, one line per instance: renamed and gzipped daily (.log.0.gz …), 7 kept; the supervisor reopens the file |
| OpenBSD | /var/log/solidfokus (root:wheel, 0755) | same | _tracerlight:_tracerlight 0640 | newsyslog, one line per instance: renamed and gzipped daily, 7 kept, then the instance is restarted (a gap of a few seconds, up to about 15 s if the telemetry endpoint is unreachable) |
| Windows | %ProgramData%\solidfokus\logs (SYSTEM, Administrators, the service accounts) | tracerlight-<role>-<tag>.log | the service's virtual account | built in: renamed to .1 … .5 above 10 MiB, checked every 30 s, no restart |
- Each file holds both the stats records and the operational log of one instance.
- Volume at the default
-i 1: about 37.5 MB per day per client instance (about 430 bytes per record) and about 17.5 MB per day per server instance (about 200 bytes per record), plus a few log lines at start and stop. - Read access: on FreeBSD and OpenBSD add your shipper's account to the group
tracerlight/_tracerlight; on Windows use theicaclsgrant above.
8. For your log shipper
This page does not configure a shipper or a backend; these are the facts a shipper configuration needs.
- Files:
/var/log/solidfokus/tracerlight-*.log(Linux, FreeBSD, OpenBSD) and%ProgramData%\solidfokus\logs\tracerlight-*.log(Windows). Read only the live.logfiles; rotated copies end in.log.0,.log.1… or.gz. - Format: one JSON object per line (newline-delimited JSON), UTF-8, no colour codes.
- Telling lines apart: stats records have the key
event(statsorfinal); log records havelevel. Client stats havertt_avg_ns; server stats havepackets_received. - Plain text: some start-up errors and warnings are plain text, not JSON, for example
Error: failed to bind 127.0.0.1:9002: … Address in use (os error 98). Keep them; they explain why an instance stopped. - Role and tag: from the file name,
tracerlight-(client|server)-<tag>.log. The tag is also in every stats record (tag). - Host: no record carries the host name, the target address or the version (the version is in the start-up line
tracerlight starting). Add the host in the shipper if you need it. - Rotation: on Linux the file is truncated in place (
copytruncate); on FreeBSD, OpenBSD and Windows it is renamed and a new file is started. The shipper has to handle both. - End of a rotated file: if the telemetry endpoint is unreachable, a rotated file can end with a plain-text
POST actor drain timed outwarning after the final stats record. - First line: from 2.22.0 the start-up banner and the
tracerlight startingline includeroleandpid, andtagwhen--tagis set, so the first line is unique per process on a host. - Counters: cumulative since the instance started; they start again from 0 when it restarts (upgrade, reboot, OpenBSD rotation). Compute rates from differences and treat a decrease as a restart.
- Timestamps: UTC. Stats records: RFC 3339 with nanoseconds and
+00:00; log records: microseconds andZ.
9. Records
The field-by-field reference for client, server and log records, with real sample lines, is on the install page: Install Tracerlight, JSON output. In short: a stats record every interval, one final record on a clean stop (SIGINT, SIGTERM, a service stop); counters are cumulative, RTT fields cover only the interval, and an RTT of 0 means no measurement in that interval. kill -9, a crash or power loss write no final record. From 2.22.0, SIGHUP to a service is ignored; SIGHUP to a foreground run with a terminal is a clean stop and writes a final record.
10. Verify
A loopback test with the same flags as the services, without installing anything (Linux, FreeBSD or OpenBSD shell; needs jq):
mkdir -p /tmp/tl && cd /tmp/tl
tracerlight --server --tag t1 -o json --log-format json -k 42 -p 9000 -n 4 127.0.0.1 >> tracerlight-server-t1.log 2>&1 &
tracerlight --tag c1-t1 -o json --log-format json -k 42 -p 9000 -n 4 -r 32 --duration 10 127.0.0.1 >> tracerlight-client-c1-t1.log 2>&1; echo "client exit=$?"
kill %1; wait
tail -n 1 tracerlight-client-c1-t1.log | jq -r '.event + " " + .tag + " lost=" + (.lost|tostring)'
tail -n 1 tracerlight-server-t1.log | jq -r '.event + " " + .tag'
Expected: client exit=0, final c1-t1 lost=0 and final t1. The server stop takes about 5 s (its drain). Then on each host run the checklist.
11. Troubleshooting
| Symptom | Cause | Check and fix |
|---|---|---|
| Linux: no log file, unit fails at start | systemd older than 240 (no append:), a missing /var/log/solidfokus or arguments file | systemctl --version, systemctl status tracerlight-server@srv1, journalctl -u tracerlight-server@srv1; create the directory or file |
Linux: the log still grows in the renamed file after rotation, or a postrotate HUP does nothing | Tracerlight does not reopen a log on SIGHUP; from 2.22.0 a service ignores SIGHUP | Linux: use copytruncate (a HUP will not reopen the file). FreeBSD: the newsyslog pid file must be the instance's /var/run/tracerlight-…pid (the supervisor, which does reopen) |
A server instance does not start: Error: failed to bind … | its range overlaps another server, or a client socket holds a port | port rule (OpenBSD: see the ephemeral range note there); bind failures |
FreeBSD: must not set --server, --tag … or must start with server_ or client_ | the args repeat flags the script adds, or the id is wrong | remove those flags from tracerlight_<id>_args; ids are server_… or client_… |
OpenBSD: rcctl rejects the name | a - in the script name | write the tag's - as _ in the file name |
| A client file shows only probing lines, no stats | the server does not answer (key, firewall, server down) | no probe reply |
| Loss in client files around a server restart | a crash or kill -9 instead of a graceful stop | loss around an upgrade |
| Windows: service installed but does not start | the .exe is under the user profile | Windows start-up |
| Windows: the log grows past 10 MiB | another process holds the file open without delete sharing, so the rename fails | make your shipper open the file with delete sharing, or stop it briefly |
| Your shipper cannot read the files | owner, group or permission list | log files; Windows: the icacls grant again after each install |
| Records carry a different tag than the file name | the tag was set by hand in the arguments | remove -t from the arguments (Linux, BSD); on Windows reinstall with matching name and -t |
| BSD: a copied rc.d script runs an old binary | hard-coded path | rc.d path |
More symptoms: Troubleshooting.
12. Upgrade
Upgrade all clients first, then the servers (why and details). On each host replace /usr/local/bin/tracerlight with the verified new binary, then restart every instance on that host:
# Linux
systemctl restart 'tracerlight-client@*'
systemctl restart 'tracerlight-server@*'
# FreeBSD
for i in $(sysrc -n tracerlight_instances); do case $i in client_*) service tracerlight restart $i;; esac; done
for i in $(sysrc -n tracerlight_instances); do case $i in server_*) service tracerlight restart $i;; esac; done
# OpenBSD
for s in /etc/rc.d/tracerlight_client_*; do rcctl restart ${s##*/}; done
for s in /etc/rc.d/tracerlight_server_*; do rcctl restart ${s##*/}; done
# Windows (elevated): the .exe is locked while a service runs
Stop-Service tracerlight-*
Copy-Item "$env:TEMP\tracerlight-new.exe" "C:\Program Files\SolidFokus\tracerlight.exe" -Force
Start-Service tracerlight-server-*
Start-Service tracerlight-client-*
In the log files an upgrade shows as a final record, a new tracerlight starting line with the new version, and counters starting again from 0.
13. Test status
This page applies to 2.22.1-f136bd5. Tested with the earlier builds named in each note; the newer releases change only the --license text. The command lines and log files of this page were tested on Linux over loopback with 2.21.0-6f573b6 (two servers and two clients on one host, the records and tags in each file, an overlapping server range failing, and the verify test above). The FreeBSD script was tested on FreeBSD 15.1 (2026-11-23) (see FreeBSD). On 2026-11-26 the page was run on Ubuntu 24.04, FreeBSD 15.1, OpenBSD 8.0 and Windows Server 2022, with clients on each host measuring servers on the others; see the note in each OS section. On 2026-11-27 the OpenBSD rotation lines were run as printed on OpenBSD 7.9 and 8.0 (see OpenBSD). The other service setups are labelled not yet tested on a real host above until they have been run on each OS.