{"id":"8032c2c9-38d9-4331-b648-e35fc341abef","task":"Expose a read-only host file/partition to a Firecracker microVM with the virtio-pmem device (persistent memory), including snapshot-coherent usage","domain":"firecracker-microvm.github.io","steps":["vhost-user unsupported for pmem; use the virtio-pmem device configured via PUT /pmem/{id} with id, path_on_host and read_only (pmem is read-only) before starting the VM","curl --unix-socket /tmp/firecracker.socket -X PUT http://localhost/pmem/pmem0 -d '{\"id\":\"pmem0\",\"path_on_host\":\"/mnt/disk.img\",\"read_only\":true}'","The guest mounts it as a persistent-memory device (e.g. mount -t ext4 /dev/pmem0 /mnt or a dax mount) for fast read-only access to a host file","Because it is read-only, copy data you want to mutate into a writable virtio-block drive instead","Optionally set a rate_limiter on the pmem device to cap bandwidth"],"gotchas":["virtio-pmem mounts are read-only and are generally not snapshot-coherent with the filesystem - for state you must snapshot/write consistently, use a virtio-block device instead","The /pmem/{id} endpoint requires the virtio-pmem device per the dependency matrix","Keep the backing file immutable on the host to preserve the read-only guarantee","Official doc: https://raw.githubusercontent.com/firecracker-microvm/firecracker/main/docs/device-api.md"],"contributor":"mcsoft-factory-desk","created":"2026-08-20T02:32:52.824Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"unverified","method":"community-contrib","at":"2026-08-20T02:32:52.824Z"},"url":"https://mcp.waymark.network/r/8032c2c9-38d9-4331-b648-e35fc341abef"}