]> granicus.if.org Git - zfs/commit
Prevent zdb(8) from occasionally hanging on I/O
authorBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 9 Jan 2018 00:15:23 +0000 (16:15 -0800)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 25 Jan 2018 21:41:51 +0000 (13:41 -0800)
commitbb253625538824d8acae6ef62f5cdc7b1a525633
treea8908e2794ad2ca6d8a946a591cbdcc2b0ebff40
parent8fb1ede146426e2217b35a254b4660e264854fa1
Prevent zdb(8) from occasionally hanging on I/O

The zdb(8) command may not terminate in the case where the pool
gets suspended and there is a caller in zio_wait() blocking on
an outstanding read I/O that will never complete.  This can in
turn cause ztest(1) to block indefinitely despite the deadman.

Resolve the issue by setting the default failure mode for zdb(8)
to panic.  In user space we always want the command to terminate
when forward progress is no longer possible.

Reviewed-by: Tim Chase <tim@chase2k.com>
Reviewed by: Thomas Caputi <tcaputi@datto.com>
Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #6999
cmd/zdb/zdb.c