#23842·netdata

[Bug]: FreeBSD collector triggers kernel panic in vmtotal() sysctl handler

Author: davidfi01Created Sep 11, 2026Updated Sep 15, 2026
Labelsbugneeds triage

Bug description

Describe the bug

Netdata's FreeBSD plugin ([plugins] freebsd = yes in netdata.conf) polls the vm.vmtotal sysctl at its normal collection interval. On our box, this eventually triggers a FreeBSD kernel panic — a page fault inside the kernel's own vmtotal() sysctl handler, not inside netdata's own code.

Crash detail

OPNsense 26.7 (FreeBSD 15.1-RELEASE-p3 stable/26.7-n283797-10516aac4165), Intel N200.

panic: page fault current process = (P[freebsd]) trap number = 12 (Fatal trap 12: page fault while in kernel mode) Uptime: 22h51m37s

vpanic() -> panic() -> trap_pfault() -> calltrap() vmtotal() at vmtotal+0x1ad sysctl_root_handler_locked() sysctl_root() userland_sysctl() sys___sysctl() amd64_syscall() --- syscall (202, FreeBSD ELF64, __sysctl) ---

"current process" is netdata's own FreeBSD collector thread (P[freebsd]), caught mid-syscall when the kernel faulted.

Workaround in place

Disabled the freebsd plugin entirely (netdata.conf: freebsd = no). No further panics since. Other collectors (apps.plugin, go.d.plugin) unaffected and still running normally.

Expected behavior

Expected behavior

Either the collector should survive without crashing the kernel, or the FreeBSD plugin should poll vm.vmtotal at reduced frequency / with defensive error handling if this kernel bug is already known upstream.

Steps to reproduce

1.To Reproduce

Run netdata's FreeBSD plugin (default 1-second interval) against vm.vmtotal on a FreeBSD 15.1 box for an extended period. Took ~23 hours of continuous uptime to reproduce here — this looks like a narrow kernel-side race that only shows up under sustained, frequent polling. 2. 3. ...

Installation method

kickstart.sh

System info

**Environment**

- Netdata: (please check `netdata -v` on your box before posting and fill in — see note below)
- OPNsense 26.7 / FreeBSD 15.1-RELEASE-p3 stable/26.7-n283797-10516aac4165
- Intel N200, amd64

Netdata build info

**Environment**

- Netdata: (please check `netdata -v` on your box before posting and fill in — see note below)
- OPNsense 26.7 / FreeBSD 15.1-RELEASE-p3 stable/26.7-n283797-10516aac4165
- Intel N200, amd64

Additional info

No response