{
  "slug": "o-append",
  "term": "O_APPEND",
  "aliases": [
    "append mode"
  ],
  "definition": "O_APPEND is a file-status flag that combines positioning at the current end of a file with each write as one atomic operation.",
  "note": "The status flag belongs to the open file description, so duplicated descriptors share it. Linux documents races when concurrent append is simulated on NFS; do not transfer a local-file guarantee to every network mount. [open-api] RWF_APPEND requests append for one pwritev2 operation; its supplied offset does not select the write position, while offset -1 also updates the current offset. [readv-api]",
  "advantages": [
    "Avoids a separate seek-to-end followed by write for an append operation."
  ],
  "limitations": [
    "Does not make a multi-call record indivisible or request durable completion.",
    "Short writes still require byte-count accounting and a concurrency policy."
  ],
  "related": [
    "pwrite",
    "short-write",
    "open-file-description",
    "o-sync",
    "advisory-file-lock"
  ],
  "citations": [
    {
      "id": "open-api",
      "title": "Linux man-pages 6.19: open(2), O_APPEND and open file descriptions",
      "url": "https://man7.org/linux/man-pages/man2/open.2.html",
      "accessed": "2026-10-17"
    },
    {
      "id": "readv-api",
      "title": "Linux man-pages 6.19: readv(2), RWF_APPEND and RWF_NOAPPEND",
      "url": "https://man7.org/linux/man-pages/man2/readv.2.html",
      "accessed": "2026-10-17"
    },
    {
      "id": "write-api",
      "title": "Linux man-pages 6.19: write(2), partial writes and errors",
      "url": "https://man7.org/linux/man-pages/man2/write.2.html",
      "accessed": "2026-10-17"
    },
    {
      "id": "hesela-publication",
      "title": "Hesela: Atomic rename is not a durable commit",
      "url": "https://hesela.com/analyses/atomic-rename-directory-durability/",
      "accessed": "2026-10-17"
    }
  ],
  "status": "shipping",
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-10-17"
}
