{
  "slug": "metadata-update-dependency",
  "term": "Metadata update dependency",
  "aliases": [],
  "definition": "A metadata update dependency is an ordering requirement between persistent changes needed to preserve a filesystem invariant.",
  "note": "Ordering changes and recording recovery information are different consistency strategies. [compare2000]\n\nIn a rename the new directory entry must reach stable storage before the old one is removed, otherwise a crash between the writes can leave neither name. Three rules cover such cases: never reset an old pointer before the new one is set, never reuse a resource before all pointers to it are nullified, and never point to a structure before it is initialised. The 1994 analysis assumes each individual update is atomic. [gangerpatt] Sector-sized updates are not by themselves proof of power-fail atomicity on a particular device. [featherstitch2007]\n\nEnforcing order with synchronous writes is so slow that implementations skipped some dependencies, which could expose a deleted file's data. Soft updates track dependencies per update rather than per block and temporarily roll back pending changes when a block is written. [gangerpatt] Per-block tracking fails when a create and a delete share a directory block and an inode block, because they need opposite write orders. [compare2000]\n\nSoft updates came within 5% of a memory-based file system and ran more than twice as fast as synchronous writes on metadata-heavy benchmarks. [gangerpatt] On a news-server workload they reached 87% of an unprotected baseline with 13% more disk writes, and after a crash only allocated-but-free blocks and inodes remained to fix in the background. [compare2000]\n\nFeatherstitch permits dependent patches to commit together within one block. Across blocks, a predecessor that is merely in flight does not satisfy the dependency: the controller may finish the dependent block first. This is a commitment-order rule, not a promise of atomic block writes. [featherstitch2007]",
  "status": "shipping",
  "advantages": [],
  "limitations": [
    {
      "text": "An ordering constraint does not itself provide atomicity for an entire application transaction.",
      "citationIds": [
        "compare2000"
      ]
    },
    {
      "text": "Ordering relies on the storage stack honouring write order, which a disk that does not reliably flush its cache defeats, and the rules are hard to implement correctly.",
      "citationIds": [
        "nofs"
      ]
    },
    {
      "text": "Featherstitch permits only one pending version per block; its safety invariants do not prove eventual completion (liveness).",
      "citationIds": [
        "featherstitch2007"
      ]
    },
    {
      "text": "Featherstitch requires completion reports to mean stable storage, not volatile cache acknowledgement; the checker cannot verify that device promise.",
      "citationIds": [
        "featherstitch2007"
      ]
    }
  ],
  "related": [
    "featherstitch",
    "soft-updates",
    "persistence-ordering",
    "filesystem-consistency-invariant",
    "patchgroup",
    "hard-patch"
  ],
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "citations": [
    {
      "id": "compare2000",
      "title": "Seltzer et al. Journaling Versus Soft Updates: Asynchronous Meta-data Protection in File Systems. USENIX ATC 2000, pp. 71-84.",
      "url": "https://www.usenix.org/legacy/event/usenix2000/general/full_papers/seltzer/seltzer_html/",
      "accessed": "2026-10-15"
    },
    {
      "id": "hesela-soft",
      "title": "Hesela: Soft updates and metadata ordering",
      "url": "https://hesela.com/analyses/soft-updates-metadata-ordering/",
      "accessed": "2026-10-15"
    },
    {
      "id": "gangerpatt",
      "title": "Ganger and Patt. Metadata Update Performance in File Systems. USENIX OSDI 1994, pp. 49-60.",
      "url": "https://users.ece.cmu.edu/~ganger/papers/osdi94.pdf",
      "accessed": "2026-10-16"
    },
    {
      "id": "nofs",
      "title": "Chidambaram, Sharma, Arpaci-Dusseau and Arpaci-Dusseau. Consistency Without Ordering. USENIX FAST 2012.",
      "url": "https://www.usenix.org/system/files/conference/fast12/chidambaram.pdf",
      "accessed": "2026-10-16"
    },
    {
      "id": "featherstitch2007",
      "title": "Frost et al. Generalized File System Dependencies. SOSP 2007, sections 3.1-3.3 and 7.",
      "url": "https://read.seas.harvard.edu/~kohler/pubs/frost07generalized.pdf",
      "accessed": "2026-11-13"
    }
  ],
  "updated": "2026-11-30",
  "provenance": [
    "Soft updates are the 1994 authors' own proposal, and three of the six authors of the 2000 comparison also worked on soft updates, so both evaluations are partly self-evaluations.",
    "The 1994 numbers come from one operating system and one disk of that period; the percentages are workload-specific.",
    "The 2012 paper proposes back-references as an alternative to ordering, so its criticism of soft updates is the view of a competing design.",
    "In the create-delete example the block-level dependency graph has a cycle, while the graph over individual pointers has none.",
    "The 2026-11-12 source review adds the same-block and in-flight distinction; the accompanying constructed checker is not an execution of Featherstitch.",
    "The checker assumes one in-flight version per block label. Its snapshot predicate does not validate submission transitions or liveness; section 3.2 treats those separately."
  ]
}
