zfs
zfs copied to clipboard
7ddc1f737 breaks kstat
System information
FreeBSD CURRENT as of today zfs-2.2.99-559-FreeBSD_g1147a2797 zfs-kmod-2.2.99-559-FreeBSD_g1147a2797
Describe the problem you're observing
The change 7ddc1f737 did not update empty_dataset_kstats structure. Surprisingly compilers don't object at this and act as if initializer was a sparse one.
On FreeBSD the structure is used to initialize the sysctl tree in kstat_install. First, all fields after new ones or shifted, displaying values of wrong counters. Second, the least 3 entries are uninitialized and kstat_install_named would execute installation of the very last oid 4 times, resulting in an error from sysctl(9):
See this email thread: https://lists.freebsd.org/archives/freebsd-current/2024-August/006285.html
Describe how to reproduce the problem
Update to most recent OpenZFS.