Skip to content

The command line

tpi controls a board from a shell. Upstream ships it; this fork extends it to reach the endpoints the fork added, which until 1.1.0 were reachable only from the web interface.

That gap mattered more than it sounds. On a headless rack the CLI is what you script and put in a runbook; the interface is what you open when you are already looking at the machine. Shipping a feature to the browser alone means shipping it to the half of the workflow that cannot be automated.

command what it does
tpi firmware list every version this board could install, across all sources
tpi firmware install <version> install one of them
tpi firmware check is there anything newer
tpi firmware sources where the board looks
tpi about firmware, bmcd, kernel, board identity
tpi thermal temperatures
tpi hostname [<name>] the board's name, live and after the next boot
tpi ntp show | set <servers…> the time sources, and how the clock is doing
tpi config export | import every setting on the board, as one file

tpi firmware --file X still works and still means upload. It is upstream's documented spelling and is already in people's scripts, so firmware grew subcommands around it rather than replacing it.

tpi cooling is upstream's command; 1.3.0 gives it the two flags that make it mean something on a board whose fan is governed by the kernel.

flag what it does
cooling set <device> <step> --hold pause the zone's governor so the step stays
cooling set <device> --auto hand the fan back to the governor

Without --hold the command means what it always did: write the step and let the governor overrule it a few seconds later.

Terminal window
$ tpi cooling set "system fan" 6 --hold
$ tpi cooling status
|----Device-----|-Speed-|-Max Speed-|-Governor-|
|system fan | 6| 6| paused|

The Governor column reads -, not running, against a daemon older than bmcd 2.21 — that daemon does not report the field, and "the governor is running" is the one thing the column exists to say.

Terminal window
$ tpi firmware list
running v2.9.0
VERSION SOURCE TRUST SIZE
= v2.9.0 fork verified
v v2.8.1 fork verified
v v2.8.0 fork verified
^ v2.9.2 local unverified 37.2 MB
^ newer = running v older ? not comparable

The trust column is not decoration. verified means the release published a checksum and it was checked on download. tls-only means the publisher ships no checksums at all — upstream's HTTP mirror does not. unverified is a local file, whose provenance is whatever put it there. Three genuinely different things, and rendering them alike would be worse than omitting the column.

Terminal window
$ tpi firmware install v2.9.2 --yes
Done
staged v2.9.2; reboot to take it
$ tpi firmware list
running v2.9.0
staged v2.9.2 (reboot to take it)

The version is resolved against the catalogue before anything is posted, so a version no source offers fails immediately rather than half-way through a download. If two sources offer the same version, it names them and asks rather than guessing.

Terminal window
$ tpi firmware check
v2.9.0 is current
$ echo $?
0

When there is something newer it names it and exits 10 instead:

10 means an upgrade exists, so tpi firmware check || notify-me works from cron without parsing output. It is deliberately not 1, which stays "the command failed".

tpi ships twice, and the difference is worth knowing before you wonder why the one on the board never asks for a password.

on the board on your workstation
arrives via a firmware upgrade a release binary or the AUR
features localhost,native-tls default
talks to 127.0.0.1 whatever you point it at
authentication skipped — it is already root-local prompts, then caches a token
version vs bmcd always matched; they ship together floats independently

Because the workstation copy updates on its own schedule, it will regularly be older or newer than the board it is pointed at. That used to produce:

Invalid `type` parameter firmware_available

which names the query parameter tpi sent and tells you nothing. Now each command asks the board its version first:

Terminal window
$ tpi firmware list
this board runs bmcd 2.7.0; `tpi firmware list` needs 2.8.0 or newer --
upgrade the firmware first (`tpi firmware check`)

Release binaries are built for five targets — Linux (x86-64, aarch64), macOS (Intel and Apple silicon) and Windows — plus Debian packages for both Linux architectures, on the releases page.

The copy on the board needs nothing: it arrives with the firmware.

Last updated: