Module persist

Module persist 

Source
Expand description

Save/restore utilities. Defines state structures for saving/restoring a Firecracker microVM.

Structs§

GuestRegionUffdMapping
This describes the mapping between Firecracker base virtual address and offset in the buffer or file backend for a guest memory region. It is used to tell an external process/thread where to populate the guest memory data for this range.
MicrovmState
Contains the necessary state for saving/restoring a microVM.
VmInfo
Holds information related to the VM that is not part of VmState.

Enums§

CreateSnapshotError
Errors associated with creating a snapshot.
GuestMemoryFromFileError
Error type for [guest_memory_from_file].
GuestMemoryFromUffdError
Error type for [guest_memory_from_uffd]
MicrovmStateError
Errors related to saving and restoring Microvm state.
RestoreFromSnapshotError
Error type for restore_from_snapshot.
RestoreFromSnapshotGuestMemoryError
Sub-Error type for restore_from_snapshot to contain either GuestMemoryFromFileError or GuestMemoryFromUffdError within RestoreFromSnapshotError.
SnapShotStateSanityCheckError
Error type for snapshot_state_sanity_check.
SnapshotStateFromFileError
Error type for [snapshot_state_from_file]

Constants§

SNAPSHOT_VERSION
Snapshot version

Functions§

create_snapshot
Creates a Microvm snapshot.
restore_from_snapshot
Loads a Microvm snapshot producing a ‘paused’ Microvm.
snapshot_state_sanity_check
Performs sanity checks against the state file and returns specific errors.
validate_cpu_vendor
Validates that snapshot CPU vendor matches the host CPU vendor.