Articles

What the host tells you by itself

JailOps reads the notifications of devd, so a failing disk, a pool that lost a device, an uplink that went down and a jail that hit a limit show up as events in the console and in jailops events, without anyone polling.

The idea

The kernel already knows.

FreeBSD notices a lot: a disk that returns bad data, a pool that lost a device, a network cable that was pulled. It tells devd, and JailOps listens. The few notifications that an administrator acts on become events in the same stream as everything else JailOps does, so a problem shows without anyone checking for it.

Which events

Four kinds.

The events JailOps publishes from the kernel's notifications
EventWhen
host-zfs-errorA pool or a device reports a checksum, I/O, data or device error.
host-zfs-poolA device of a pool changed state or was removed, or a scrub finished or was aborted.
host-link-down, host-link-upThe uplink of a network changed state.
jail-limit-hitA jail reached a resource limit.

The first three are for administrators of the host. The last one is shown to the people who may use the jail's project.

Watching them

The same place as the rest.

The events are in the console's Events page and on the command line. Each one carries a single line of text, such as pool tank: checksum on /dev/da0.

on the host
$ jailops events

jailops doctor has a check, host.devd, that says whether the daemon is connected to devd.

Calm by design

A failing disk cannot flood you.

The same event is shown once in 30 seconds, and at most 30 events are published in a minute. A host without devd, or a socket the daemon cannot read, never stops the daemon: it tries again slowly and the doctor tells you. devd.enable: false in jailopsd.yaml turns it off.

More articles

Try it on one server.

Try the console from the screenshots, install on a clean FreeBSD 15.1 machine, or add JailOps to a host you already run.