Includes methods to start, stop and list QEMU file-restore VMs, as well as CLI commands do the latter two (start is implicit). The implementation is abstracted behind the concept of a "BlockRestoreDriver", so other methods can be implemented later (e.g. mapping directly to loop devices on the host, using other hypervisors then QEMU, etc...). Starting VMs is currently unused but will be needed for further changes. The design for the QEMU driver uses a locked 'map' file (/run/proxmox-backup/$UID/restore-vm-map.json) containing a JSON encoding of currently running VMs. VMs are addressed by a 'name', which is a systemd-unit encoded combination of repository and snapshot string, thus uniquely identifying it. Note that currently you need to run proxmox-file-restore as root to use this method of restoring. Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
7 lines
147 B
Rust
7 lines
147 B
Rust
//! Block device drivers and tools for single file restore
|
|
pub mod block_driver;
|
|
pub use block_driver::*;
|
|
|
|
mod qemu_helper;
|
|
mod block_driver_qemu;
|