Skip to main content
The kernel spec defines .mv2 as a contiguous layout:
RegionSizeNotes
Header4096 bytesContains magic, spec version (SPEC_MAJOR=2, SPEC_MINOR=1), WAL offsets
Embedded WAL1–64 MBAppend-only log written before every commit (see WAL protocol)
SegmentsVariableFrames, blobs, text chunks, vector chunks stored sequentially
Index manifestsVariableIndexManifests struct in the TOC references each index
Time Index TrackVariableOptional TimeIndexManifest (offset + length + checksum)
TOCVariableSerialized via bincode with cascading checksums
Footer48 bytes + magicCommitFooter storing toc_len, toc_hash, and generation
CommitFooter::find_last_valid_footer scans from the end of the file to locate the final valid footer, ensuring crash recovery always loads a consistent TOC.
Portability - There are no .shm, .wal, or .lock siblings; locking uses in-file byte ranges via FileLock, and verification ensures single-file compliance.