CT Backup of privileged Containers

iprigger

Renowned Member
Sep 5, 2009
190
41
93
earth!
Hi All,

pveversion -v:
proxmox-ve: 5.1-28 (running kernel: 4.13.4-1-pve)
pve-manager: 5.1-36 (running version: 5.1-36/131401db)
pve-kernel-4.13.4-1-pve: 4.13.4-26
pve-kernel-4.4.62-1-pve: 4.4.62-88
pve-kernel-4.13.8-2-pve: 4.13.8-28
pve-kernel-4.10.17-4-pve: 4.10.17-24
pve-kernel-4.10.17-2-pve: 4.10.17-20
pve-kernel-4.10.15-1-pve: 4.10.15-15
pve-kernel-4.4.35-1-pve: 4.4.35-77
pve-kernel-4.4.67-1-pve: 4.4.67-90
pve-kernel-4.10.17-3-pve: 4.10.17-23
pve-kernel-4.4.59-1-pve: 4.4.59-87
libpve-http-server-perl: 2.0-6
lvm2: 2.02.168-pve6
corosync: 2.4.2-pve3
libqb0: 1.0.1-1
pve-cluster: 5.0-15
qemu-server: 5.0-17
pve-firmware: 2.0-3
libpve-common-perl: 5.0-20
libpve-guest-common-perl: 2.0-13
libpve-access-control: 5.0-7
libpve-storage-perl: 5.0-16
pve-libspice-server1: 0.12.8-3
vncterm: 1.5-2
pve-docs: 5.1-12
pve-qemu-kvm: 2.9.1-2
pve-container: 2.0-17
pve-firewall: 3.0-3
pve-ha-manager: 2.0-3
ksm-control-daemon: 1.2-2
glusterfs-client: 3.8.8-1
lxc-pve: 2.1.0-2
lxcfs: 2.0.7-pve4
criu: 2.11.1-1~bpo90
novnc-pve: 0.6-4
smartmontools: 6.5+svn4324-1
zfsutils-linux: 0.7.3-pve1~bpo9

When trying to backup an unprivileged, running container I get errors:
INFO: starting new backup job: vzdump 227 9031 --storage VZBack --quiet 1 --mode snapshot --compress lzo --mailnotification always
INFO: Starting Backup of VM 227 (lxc)
INFO: status = running
INFO: CT Name: wlac
INFO: mode failure - some volumes do not support snapshots
INFO: trying 'suspend' mode instead
INFO: backup mode: suspend
INFO: ionice priority: 7
INFO: CT Name: CT-NAME
temporary directory is on NFS, disabling xattr and acl support, consider configuring a local tmpdir via /etc/vzdump.conf
INFO: starting first sync /proc/27955/root// to /mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tmp
INFO: Number of files: 28,096 (reg: 21,556, dir: 2,418, link: 4,092, special: 30)
INFO: Number of created files: 28,095 (reg: 21,556, dir: 2,417, link: 4,092, special: 30)
INFO: Number of deleted files: 0
INFO: Number of regular files transferred: 21,547
INFO: Total file size: 1,705,511,547 bytes
INFO: Total transferred file size: 1,698,325,235 bytes
INFO: Literal data: 1,698,330,499 bytes
INFO: Matched data: 0 bytes
INFO: File list size: 752,235
INFO: File list generation time: 0.001 seconds
INFO: File list transfer time: 0.000 seconds
INFO: Total bytes sent: 1,700,360,726
INFO: Total bytes received: 436,774
INFO: sent 1,700,360,726 bytes received 436,774 bytes 10,276,722.05 bytes/sec
INFO: total size is 1,705,511,547 speedup is 1.00
INFO: first sync finished (165 seconds)
INFO: suspend vm
INFO: starting final sync /proc/27955/root// to /mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tmp
INFO: Number of files: 28,096 (reg: 21,556, dir: 2,418, link: 4,092, special: 30)
INFO: Number of created files: 0
INFO: Number of deleted files: 0
INFO: Number of regular files transferred: 16
INFO: Total file size: 1,705,518,987 bytes
INFO: Total transferred file size: 4,957,662 bytes
INFO: Literal data: 77,000 bytes
INFO: Matched data: 4,880,662 bytes
INFO: File list size: 0
INFO: File list generation time: 0.001 seconds
INFO: File list transfer time: 0.000 seconds
INFO: Total bytes sent: 792,966
INFO: Total bytes received: 32,115
INFO: sent 792,966 bytes received 32,115 bytes 183,351.33 bytes/sec
INFO: total size is 1,705,518,987 speedup is 2,067.09
INFO: final sync finished (4 seconds)
INFO: resume vm
INFO: vm is online again after 4 seconds
INFO: creating archive '/mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tar.lzo'
INFO: tar: ./var/cache/apt/archives/partial: Cannot open: Permission denied
INFO: tar: ./var/log/nginx/access.log: Cannot open: Permission denied
INFO: tar: ./var/log/nginx/error.log: Cannot open: Permission denied
INFO: tar: ./var/log/unifi: Cannot open: Permission denied
INFO: tar: ./var/lib/postfix/master.lock: Cannot open: Permission denied
INFO: tar: ./var/lib/nginx/scgi: Cannot open: Permission denied
INFO: tar: ./var/lib/nginx/uwsgi: Cannot open: Permission denied
INFO: tar: ./var/lib/nginx/proxy: Cannot open: Permission denied
INFO: tar: ./var/lib/nginx/fastcgi: Cannot open: Permission denied
INFO: tar: ./var/lib/nginx/body: Cannot open: Permission denied
INFO: tar: ./var/lib/unifi: Cannot open: Permission denied
INFO: tar: ./var/lib/apt/lists/partial: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/saved: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/public: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/active: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/private: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/trace: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/flush: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/deferred: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/hold: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/defer: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/maildrop: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/corrupt: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/incoming: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/bounce: Cannot open: Permission denied
INFO: Total bytes written: 1299496960 (1.3GiB, 30MiB/s)
INFO: tar: Exiting with failure status due to previous errors
ERROR: Backup of VM 227 failed - command 'set -o pipefail && lxc-usernsexec -m u:0:100000:65536 -m g:0:100000:65536 -- tar cpf - --totals --one-file-system -p --sparse --numeric-owner --acls --xattrs '--xattrs-include=user.*' '--xattrs-include=security.capability' '--warning=no-file-ignored' '--warning=no-xattr-write' --one-file-system '--warning=no-file-ignored' '--directory=/mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tmp' ./etc/vzdump/pct.conf '--directory=/mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tmp' --no-anchored '--exclude=lost+found' --anchored '--exclude=./tmp/?*' '--exclude=./var/tmp/?*' '--exclude=./var/run/?*.pid' . | lzop >/mnt/pve/VZBack/dump/vzdump-lxc-227-2017_12_13-23_00_03.tar.dat' failed: exit code 2

INFO: Starting Backup of VM 9031 (lxc)
INFO: status = running
INFO: CT Name: HOSTNAME.DOMAINNAME.TLD
INFO: mode failure - some volumes do not support snapshots
INFO: trying 'suspend' mode instead
INFO: backup mode: suspend
INFO: ionice priority: 7
INFO: CT Name: unifi.invisia.ch
temporary directory is on NFS, disabling xattr and acl support, consider configuring a local tmpdir via /etc/vzdump.conf
INFO: starting first sync /proc/28573/root// to /mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tmp
INFO: Number of files: 27,158 (reg: 20,748, dir: 2,323, link: 4,057, special: 30)
INFO: Number of created files: 27,157 (reg: 20,748, dir: 2,322, link: 4,057, special: 30)
INFO: Number of deleted files: 0
INFO: Number of regular files transferred: 20,739
INFO: Total file size: 1,690,320,891 bytes
INFO: Total transferred file size: 1,683,135,930 bytes
INFO: Literal data: 1,683,139,571 bytes
INFO: Matched data: 0 bytes
INFO: File list size: 720,835
INFO: File list generation time: 0.001 seconds
INFO: File list transfer time: 0.000 seconds
INFO: Total bytes sent: 1,685,097,238
INFO: Total bytes received: 420,825
INFO: sent 1,685,097,238 bytes received 420,825 bytes 9,338,050.21 bytes/sec
INFO: total size is 1,690,320,891 speedup is 1.00
INFO: first sync finished (180 seconds)
INFO: suspend vm
INFO: starting final sync /proc/28573/root// to /mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tmp
INFO: Number of files: 27,158 (reg: 20,748, dir: 2,323, link: 4,057, special: 30)
INFO: Number of created files: 0
INFO: Number of deleted files: 0
INFO: Number of regular files transferred: 4
INFO: Total file size: 1,690,324,552 bytes
INFO: Total transferred file size: 1,041,655 bytes
INFO: Literal data: 6,057 bytes
INFO: Matched data: 1,035,598 bytes
INFO: File list size: 0
INFO: File list generation time: 0.001 seconds
INFO: File list transfer time: 0.000 seconds
INFO: Total bytes sent: 672,088
INFO: Total bytes received: 9,689
INFO: sent 672,088 bytes received 9,689 bytes 151,506.00 bytes/sec
INFO: total size is 1,690,324,552 speedup is 2,479.29
INFO: final sync finished (4 seconds)
INFO: resume vm
INFO: vm is online again after 4 seconds
INFO: creating archive '/mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tar.lzo'
INFO: tar: ./var/cache/apt/archives/partial: Cannot open: Permission denied
INFO: tar: ./var/log/unifi: Cannot open: Permission denied
INFO: tar: ./var/lib/postfix/master.lock: Cannot open: Permission denied
INFO: tar: ./var/lib/unifi: Cannot open: Permission denied
INFO: tar: ./var/lib/apt/lists/partial: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/saved: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/public: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/active: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/private: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/trace: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/flush: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/deferred: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/hold: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/defer: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/maildrop: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/corrupt: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/incoming: Cannot open: Permission denied
INFO: tar: ./var/spool/postfix/bounce: Cannot open: Permission denied
INFO: Total bytes written: 1281730560 (1.2GiB, 30MiB/s)
INFO: tar: Exiting with failure status due to previous errors
ERROR: Backup of VM 9031 failed - command 'set -o pipefail && lxc-usernsexec -m u:0:100000:65536 -m g:0:100000:65536 -- tar cpf - --totals --one-file-system -p --sparse --numeric-owner --acls --xattrs '--xattrs-include=user.*' '--xattrs-include=security.capability' '--warning=no-file-ignored' '--warning=no-xattr-write' --one-file-system '--warning=no-file-ignored' '--directory=/mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tmp' ./etc/vzdump/pct.conf '--directory=/mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tmp' --no-anchored '--exclude=lost+found' --anchored '--exclude=./tmp/?*' '--exclude=./var/tmp/?*' '--exclude=./var/run/?*.pid' . | lzop >/mnt/pve/VZBack/dump/vzdump-lxc-9031-2017_12_13-23_03_59.tar.dat' failed: exit code 2
INFO: Backup job finished with errors
TASK ERROR: job errors

The Container does reside on an NFS share. When doing a backup whilst the container is stopped, everything works.

When I restore without stting the "unprivileged" flag, I can backup the container whilst it's running, too.

Any ideas on this?

THANKS!

Tobias
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!