Backups not working with "unprivileged" containers.

Alex Metcalre

New Member
May 10, 2019
20
0
1
51
When creating a new container, if the "unprivileged" box is ticked, the container cannot be backed up.

Restoring a container as "unprivileged" means that it won't start.

Backing up VMs and "priviledged" containers works.

Hlep ...

PVE 5.4-6
Clustered.
One node from two has this problem.
Node has been rebooted.
 
hi,

what error do you get while trying to back up the unprivileged container?
 
Hi,

The tar / permission denied one.

1.png
2.png

No problems on another node, no problems with existing (priviledged containers / unprivileged: no) containers, no problems with VM

Just this one very repeatable scenario. I've gone through every related post I can find about containers not backing up, but none fit this scenario.

Help appreciated.
 
This seems like a permissions problem with your /mnt/pve/proxmox-backups. The backup is running as the unprivileged user who has no permissions to write on that path. The privileged containers are not running as a mapped uid/gid. Try to set a more broad permissions on the backup directory and retry the backup
 
Hi Ramrot,

Thanks for this, and I know what you mean. The crazy thing is that on the other node it works just fine.
 
Does this completes successfully on both nodes?


Code:
lxc-usernsexec -m u:0:100000:65536 -m g:0:100000:65536 -- touch /mnt/pve/proxmox-backups/testfile
 
Thanks Ramrot,

This failed on both nodes.
touch: cannot touch '/mnt/pve/proxmox-backups/testfile': Permission denied
 
So it seems that you don't have the correct permissions. Are you using an nfs storage for the proxmox-backups directory? If so can you share the /etc/exports file from the nfs server and the /etc/fstab of the nfs client?
 
Hi Ramrot,

Sorry for the delay:

/etc/exports
============

/volume2/proxmox-backups

10.30.200.85(rw,async,no_wdelay,no_root_squash,insecure_locks,sec=sys,anonuid=1025,anongid=100)
10.30.200.60(rw,async,no_wdelay,no_root_squash,insecure_locks,sec=sys,anonuid=1025,anongid=100)
10.30.200.80(rw,async,no_wdelay,no_root_squash,insecure_locks,sec=sys,anonuid=1025,anongid=100)

/etc/fstab
- it's a proxmox node, and so is empty.

This is the row from the cluster storage settings

1568973128781.png