-
Notifications
You must be signed in to change notification settings - Fork 413
Open
Labels
Description
Summary
Add checkpoint/restore integration tests to `tests/contest` equivalent to `tests/integration/checkpoint.bats` in runc, then make youki pass them.
Motivation
The `contest` framework (Rust-based OCI runtime integration tests) currently has no coverage for checkpoint/restore functionality. The existing BATS-based tests in runc's `checkpoint.bats` cover this area but are not available through `contest`.
Phase 1: Implement contest tests
Add the following tests to `tests/contest`. Tests are skipped when running with youki (not yet implemented) and when CRIU is not installed.
- checkpoint and restore
- checkpoint and restore (bind mount, destination is symlink)
- checkpoint and restore (with --debug)
- checkpoint and restore (cgroupns)
- checkpoint and restore with netdevice
- checkpoint and restore with netdevice (bind mount, destination is symlink)
- checkpoint and restore with netdevice (with --debug)
- checkpoint and restore with netdevice (cgroupns)
- checkpoint --pre-dump (bad --parent-path)
- checkpoint --pre-dump and restore
- checkpoint --lazy-pages and restore
- checkpoint and restore in external network namespace
- checkpoint and restore with container specific CRIU config
- checkpoint and restore with nested bind mounts
- checkpoint then restore into a different cgroup (via --manage-cgroups-mode ignore)
- checkpoint/restore and exec
Phase 2: Make youki pass the tests
Once the contest tests are in place, implement checkpoint/restore support in youki so that all of the above tests pass.
- checkpoint and restore
- checkpoint and restore (bind mount, destination is symlink)
- checkpoint and restore (with --debug)
- checkpoint and restore (cgroupns)
- checkpoint and restore with netdevice
- checkpoint and restore with netdevice (bind mount, destination is symlink)
- checkpoint and restore with netdevice (with --debug)
- checkpoint and restore with netdevice (cgroupns)
- checkpoint --pre-dump (bad --parent-path)
- checkpoint --pre-dump and restore
- checkpoint --lazy-pages and restore
- checkpoint and restore in external network namespace
- checkpoint and restore with container specific CRIU config
- checkpoint and restore with nested bind mounts
- checkpoint then restore into a different cgroup (via --manage-cgroups-mode ignore)
- checkpoint/restore and exec
Notes
- Some tests have additional preconditions (e.g. `mem_dirty_track` / `uffd-noncoop` CRIU features, cgroups v1 + cgroupns).
- Requires adding `DummyDevice` / `NetNamespace` utilities to `tests/contest/contest/src/utils/net.rs` to support netdevice tests.
Reactions are currently unavailable