Project

General

Profile

Actions

Bug #3693

closed

restore_object uses at least two transactions to restore an object

Added by Andriy Gapon over 8 years ago. Updated almost 7 years ago.

Status:
Closed
Priority:
Normal
Category:
zfs - Zettabyte File System
Start date:
2013-04-04
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:

Description

restore_object uses at least two transactions to restore an object:
  • one transaction is used for dmu_object_claim
  • another transaction is used to set compression, checksum and most importantly bonus data
  • furthermore dmu_object_reclaim internally uses multiple transactions
  • dmu_free_long_range frees chunks in separate transactions
  • dnode_reallocate is executed in a distinct transaction

The fact the dnode_allocate/ dnode_reallocate are executed in one transaction and bonus (re-)population is executed in a different transaction may lead to violation of ZFS consistency assertions if the transactions are assigned to different transaction groups.
Also, if the first transaction group is successfully written to a permanent storage, but the second transaction is lost, then an invalid dnode may be created on the stable storage.


Files

zfs_restore_object.patch (4.08 KB) zfs_restore_object.patch Andriy Gapon, 2013-04-04 02:45 PM
Actions

Also available in: Atom PDF