Skip to content

Commit 7fb7002

Browse files
oshogboamotin
authored andcommitted
Make sure we can still write data to txg
The final txgs are used only to clear out any remaining deferred frees, and we cannot write new data to them. Make sure we do not try to do so. Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Mariusz Zaborski <mariusz.zaborski@klarasystems.com> Closes openzfs#18139
1 parent 9ac28a4 commit 7fb7002

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

module/zfs/spa.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2167,6 +2167,9 @@ spa_sync_time_logger(spa_t *spa, uint64_t txg)
21672167
if (curtime < spa->spa_last_flush_txg_time + spa_flush_txg_time) {
21682168
return;
21692169
}
2170+
if (txg > spa_final_dirty_txg(spa)) {
2171+
return;
2172+
}
21702173
spa->spa_last_flush_txg_time = curtime;
21712174

21722175
tx = dmu_tx_create_assigned(spa_get_dsl(spa), txg);

0 commit comments

Comments
 (0)