zfs/lib/libzfs
Rob N 006d506547 status: report pool suspension state under failmode=continue
When failmode=continue is set and the pool suspends, both 'zpool status'
and the 'zfs/pool/state' kstat ignore it and report the normal vdev tree
state. There's no clear indicator that the pool is suspended. This is
unlike suspend in failmode=wait, or suspend due to MMP check failure,
which both report "SUSPENDED" explicitly.

This commit changes it so SUSPENDED is reported for failmode=continue
the same as for other modes.

Rationale:

The historical behaviour of failmode=continue is roughly, "press on as
though all is well". To this end, the fact that the pool had suspended
was not shown, to maintain the façade that all is well.

Its unclear why hiding this information was considered appropriate. One
possibility is that it was expected that a true pool fault would always
be reported as DEGRADED or FAULTED, and that the pool could not suspend
without these happening.

That is not necessarily true, as vdev health and suspend state are only
loosely connected, such that a pool in (apparent) good health can be
suspended for good reasons, and of course a degraded pool does not lead
to suspension. Even if that expectation were true, there's still a
difference in urgency - a degraded pool may not need to be attended to
for hours, while a suspended pool is most often unusable until an
operator intervenes.

An operator that has set failmode=continue has presumably done so
because their workload is one that can continue to operate in a useful
way when the pool suspends. In this case the operator still needs a
clear indicator that there is a problem that needs attending to.

Sponsored-by: Klara, Inc.
Sponsored-by: Wasabi Technology, Inc.
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Rob Norris <rob.norris@klarasystems.com>
Closes #15297
2024-04-30 16:48:01 +10:00
..
os zfs: support force exporting pools 2023-07-05 13:27:30 +00:00
.gitignore Clean up lib dependencies 2020-07-10 14:26:00 -07:00
Makefile.am libzfs: add keylocation=https://, backed by fetch(3) or libcurl 2022-02-16 17:58:37 -08:00
THIRDPARTYLICENSE.openssl Fix typos in lib/ 2019-09-02 17:53:27 -07:00
THIRDPARTYLICENSE.openssl.descrip Encryption patch follow-up 2017-10-11 16:54:48 -04:00
libzfs.abi zfs: support force exporting pools 2023-07-05 13:27:30 +00:00
libzfs.pc.in Spruce up pkg-config files for libzfs/libzfs_core 2020-09-04 11:11:18 -07:00
libzfs.suppr Library ABI tracking with abigail 2020-11-17 09:18:52 -08:00
libzfs_changelist.c Add 'zfs rename -u' to rename without remounting 2020-09-01 16:14:16 -07:00
libzfs_config.c Use zfs_ioctl with zfs_cmd_t in libzfs 2019-10-23 17:29:43 -07:00
libzfs_crypto.c get_key_material_https: removed bogus free() call 2022-03-17 10:22:13 -07:00
libzfs_dataset.c zfs: support force exporting pools 2023-07-05 13:27:30 +00:00
libzfs_diff.c libzfs: diff: stream_bytes: use fputc, %hho formats chars 2022-04-01 09:58:45 -07:00
libzfs_import.c libzfs: import: zpool_clear_label: actually fail if clearing l2arc header fails 2022-04-15 14:16:59 -07:00
libzfs_iter.c lib/: set O_CLOEXEC on all fds 2021-04-14 13:23:07 -07:00
libzfs_mount.c zpool_disable_datasets: on Linux, detach mounts when forcing export 2023-07-05 13:27:30 +00:00
libzfs_pool.c status: report pool suspension state under failmode=continue 2024-04-30 16:48:01 +10:00
libzfs_sendrecv.c Reject zfs send -RI with nonexistent fromsnap 2022-06-06 16:57:41 -07:00
libzfs_status.c zfs: support force exporting pools 2023-07-05 13:27:30 +00:00
libzfs_util.c libzfs: add keylocation=https://, backed by fetch(3) or libcurl 2022-02-16 17:58:37 -08:00