firecracker icon indicating copy to clipboard operation
firecracker copied to clipboard

snapshot: add `container_snapshot_path` to load snapshot request

Open CuriousGeorgiy opened this issue 2 years ago • 1 comments

Changes

Firecracker does not support renaming resources at snapshot-restore, so as a workaround we manually substitute the VM state with the path of the block device backing the container snapshot to the path of the new container snapshot path received from the LoadSnapshot request.

Reason

When a snapshot of a VM created by firecracker-containerd is restored, due to the non-deterministic container snapshot path (it depends on the containerd snapshotter implementation), the container snapshot path at the time of the snapshot creation is different from the container snapshot path at the time of the snapshot loading.

Closes #4014

License Acceptance

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check CONTRIBUTING.md.

PR Checklist

  • [x] If a specific issue led to this PR, this PR closes the issue.
  • [ ] The description of changes is clear and encompassing.
  • [ ] Any required documentation changes (code and docs) are included in this PR.
  • [ ] API changes follow the Runbook for Firecracker API changes.
  • [ ] User-facing changes are mentioned in CHANGELOG.md.
  • [ ] All added/changed functionality is tested.
  • [ ] New TODOs link to an issue.
  • [ ] Commits meet contribution quality standards.

  • [x] This functionality cannot be added in rust-vmm.

CuriousGeorgiy avatar Aug 24 '23 10:08 CuriousGeorgiy

This PR is not intended to be merged, it just serves as an illustration of what I want to achieve in #4014.

CuriousGeorgiy avatar Aug 24 '23 10:08 CuriousGeorgiy