So I want to use a tmpdir that has zfs as underlying storage, with sync = disabled. This means that writing the tar to that tmp dir should write straight into RAM, which I think should be much faster.
This is my vzdump.conf:
Now when I want to backup a small, unpriviliged container, I get this error:
I'm guessing the container itself needs access to that temporary folder? Why does it need permission if I run this as the root proxmox user? And how do I give it permission for all the unprivileged containers that I run? The backup runs fine if the tmpdir is set at the default location.
What's the best way to solve this?
This is my vzdump.conf:
Code:
tmpdir: /pool/backup/proxmox/vzdump/tmp/
dumpdir: /pool/backup/proxmox/vzdump
#storage: STORAGE_ID
mode: snapshot
#bwlimit: KBPS
#ionice: PRI
#lockwait: MINUTES
#stopwait: MINUTES
#size: MB
#stdexcludes: BOOLEAN
maxfiles: 6
#script: FILENAME
#exclude-path: PATHLIST
compress: gzip
pigz: 16
Now when I want to backup a small, unpriviliged container, I get this error:
Code:
INFO: starting new backup job: vzdump 102
INFO: Starting Backup of VM 102 (lxc)
INFO: Backup started at 2020-02-26 15:31:54
INFO: status = running
INFO: CT Name: test
INFO: backup mode: snapshot
INFO: ionice priority: 7
INFO: create storage snapshot 'vzdump'
INFO: creating archive '/pool/backup/proxmox/vzdump/vzdump-lxc-102-2020_02_26-15_31_54.tar.gz'
INFO: tar: /pool/backup/proxmox/vzdump/tmp/vzdumptmp199077: Cannot open: Permission denied
INFO: tar: Error is not recoverable: exiting now
INFO: remove vzdump snapshot
ERROR: Backup of VM 102 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=/pool/backup/proxmox/vzdump/tmp/vzdumptmp199077' ./etc/vzdump/pct.conf ./etc/vzdump/pct.fw '--directory=/mnt/vzsnap0' --no-anchored '--exclude=lost+found' --anchored '--exclude=./tmp/?*' '--exclude=./var/tmp/?*' '--exclude=./var/run/?*.pid' ./ | pigz -p 38 --rsyncable >/pool/backup/proxmox/vzdump/vzdump-lxc-102-2020_02_26-15_31_54.tar.dat' failed: exit code 2
INFO: Failed at 2020-02-26 15:31:55
INFO: Backup job finished with errors
job errors
I'm guessing the container itself needs access to that temporary folder? Why does it need permission if I run this as the root proxmox user? And how do I give it permission for all the unprivileged containers that I run? The backup runs fine if the tmpdir is set at the default location.
What's the best way to solve this?