[pve-devel] [RFC v2 pve-container pve-manager 0/3] add partial restore

Christian Ebner c.ebner at proxmox.com
Mon Oct 23 13:18:32 CEST 2023


This patch series adds functionality to partially restore containers
from backup, by allowing the user to selectively include/exclude
mountpoints for restore. Mountpoints not included in the backup will not
be deleted and recreated but rather attached to the container as unused
disk after the restore. The same is true for mountpoints selected by the
user to be excluded during restore.

As is, there is a slight discrepancy in partial restore behaviour for
PBS based and tar based backups, in cases where mountpoints are mounted
in the file tree of another mountpoint. For tar based backups, all files
below the uppermost mountpoint excluded from backup will not be restored,
as the tar `--exclude` limits the file restore. For PBS based backups,
each mountpoint is now backed up as individual pxar archive, therefore
allowing to handle the restore more fine grained, by restoring the pxar
archive directly to the moutpoint.

This splitting of the PBS based backups into one archive per mountpoint
introduces also side effects for backups created with the previous
single root.pxar archive approach. During restore, the pxar archive per
mountpoint cannot be found, producing a soft error message. Restore of
the files is than handled directly from the main root.pxar archive.

Any feedback is highly appreciated.

pve-container:

Christian Ebner (2):
  backup: do not delete not backed-up mps on restore
  api: allow to exclude mountpoins from restore

 src/PVE/API2/LXC.pm   | 44 +++++++++++++++++++----
 src/PVE/LXC/Create.pm | 83 ++++++++++++++++++++++++++++++++++++-------
 src/PVE/VZDump/LXC.pm | 10 +++---
 3 files changed, 113 insertions(+), 24 deletions(-)

pve-manager:

Christian Ebner (1):
  ui: lxc restore: add selective mountpoint restore

 www/manager6/Makefile                     |  1 +
 www/manager6/grid/BackupRestoreTargets.js | 37 +++++++++++++++++++++++
 www/manager6/window/Restore.js            | 34 +++++++++++++++++++++
 3 files changed, 72 insertions(+)
 create mode 100644 www/manager6/grid/BackupRestoreTargets.js
-- 
2.39.2






More information about the pve-devel mailing list