I've found what appears to be a bug on PVE 6.4. I am running 5.11 kernel but have not tested on 5.4 kernel.
Containers that have a configured bind mount point will restore correctly, but any mounted file systems that exist within the bind mount tree are inaccessible until remounted on the host.
Example:
File systems are mounted on the host at /farm:
LXC container has bind mount for /farm to host /farm then is backed up and restored with "Unpriveledged" set to "No", and then started:
Confirm restored container contains bind mount of /farm to hosts /farm:
Observe contents of mounted file systems inaccessible from within container but is accessble from host:
Remount file system with identical mount method as before restore of container:
Observe contents of mounted file system in bind mount tree is now accessible within the container
Is this working as designed, and if so, why ? And if not, how best to communicate to the dev team ?
Thanks !
Linux richie 5.11.17-1-pve #1 SMP PVE 5.11.17-1~bpo10 (Wed, 12 May 2021 12:45:37 +0200) x86_64 GNU/Linux
Containers that have a configured bind mount point will restore correctly, but any mounted file systems that exist within the bind mount tree are inaccessible until remounted on the host.
Example:
File systems are mounted on the host at /farm:
Code:
root@richie:/farm# mount|grep transfer7
/dev/sde1 on /farm/transfer7 type exfat (rw,relatime,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro)
LXC container has bind mount for /farm to host /farm then is backed up and restored with "Unpriveledged" set to "No", and then started:
Code:
root@richie:/farm# pct list|egrep 'VMID|102'
VMID Status Lock Name
102 running chiapet
Confirm restored container contains bind mount of /farm to hosts /farm:
Code:
root@richie:/farm# pct df 102
MP Volume Size Used Avail Use% Path
rootfs local-lvm:vm-102-disk-0 62.5G 27.6G 31.7G 0.4 /
mp0 /farm 54.6G 46.0G 5.8G 0.8 /farm
Observe contents of mounted file systems inaccessible from within container but is accessble from host:
Code:
On container:
root@chiapet:/farm# ls transfer7/*
ls: cannot access 'transfer7/*': No such file or directory
On host:
root@richie:/farm# ls -l transfer7/
total 512
drwxr-xr-x 2 root root 131072 May 24 16:10 plots
-rwxr-xr-x 1 root root 5 May 22 13:48 sata
drwxr-xr-x 2 root root 131072 May 26 04:19 'System Volume Information'
-rwxr-xr-x 1 root root 10 May 22 13:48 transfer7
Remount file system with identical mount method as before restore of container:
Code:
root@richie:/farm# umount /farm/transfer7
root@richie:/farm# mount /dev/disk/by-label/transfer7 /farm/transfer7/
root@richie:/farm# mount|grep transfer7
/dev/sde1 on /farm/transfer7 type exfat (rw,relatime,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro)
Observe contents of mounted file system in bind mount tree is now accessible within the container
Code:
root@chiapet:/farm# ls -l transfer7/
total 512
drwxr-xr-x 2 root root 131072 May 26 04:19 'System Volume Information'
drwxr-xr-x 2 root root 131072 May 24 16:10 plots
-rwxr-xr-x 1 root root 5 May 22 13:48 sata
-rwxr-xr-x 1 root root 10 May 22 13:48 transfer7
Is this working as designed, and if so, why ? And if not, how best to communicate to the dev team ?
Thanks !
Last edited: