From 7316fdd1c0c74074c4b48a499afe4e444aa42914 Mon Sep 17 00:00:00 2001 From: Richard Yao Date: Fri, 10 Mar 2023 12:34:00 -0500 Subject: [PATCH] txg_sync should handle write errors in ZIL The txg_sync thread will see certain buffers in a DR_IN_DMU_SYNC state when ZIL is writing them out. Then it waits until the state changes, but has an assertion to check that they were not DR_NOT_OVERRIDDEN. If the data write failed with an error, ZIL will put it into the DR_NOT_OVERRIDDEN state. It looks like the code will handle that state without an issue, so we can just delete the assertion. Reviewed-by: Brian Behlendorf Signed-off-by: Richard Yao Sponsored-By: Wasabi Technology, Inc. Closes #14283 --- module/zfs/dbuf.c | 1 - 1 file changed, 1 deletion(-) diff --git a/module/zfs/dbuf.c b/module/zfs/dbuf.c index f1d2f61e73..191e5e0439 100644 --- a/module/zfs/dbuf.c +++ b/module/zfs/dbuf.c @@ -4434,7 +4434,6 @@ dbuf_sync_leaf(dbuf_dirty_record_t *dr, dmu_tx_t *tx) while (dr->dt.dl.dr_override_state == DR_IN_DMU_SYNC) { ASSERT(dn->dn_object != DMU_META_DNODE_OBJECT); cv_wait(&db->db_changed, &db->db_mtx); - ASSERT(dr->dt.dl.dr_override_state != DR_NOT_OVERRIDDEN); } /*