I have a use-case where I have some Host Folders that is actually an NFS Mount (could also be CIFS/SSHFS/...).
I then bind-mount (
I devised my own little Script (NOT specific to Proxmox VE, also used on general-purpose Debian/Ubuntu/Fedora/etc) to fix NFS/CIFS-Samba/FUSE Mountpoints that end up being stale (as well as their
https://github.com/luckylinux/fix-stale-handle
However, for Proxmox VE and LXC Containers, it doesn't really work, because even remounting the Host Mountpoint at
(and fixing the Issue from the Host point of View) doesn't actually fix the Issue in the LXC Container. The Share inside the LXC Container stays empty.
Neither does rebooting the LXC Container IIRC. I believe the only "Solution" that works is first stopping the LXC Container, wait a bit, then start the LXC Container again.
I tried some Things in this little Script here to analyse which are the LXC Mountpoints that might depend on NFS/CIFS/etc Shares, but no actual implementation yet:
https://github.com/luckylinux/fix-stale-handle/blob/main/list-pve-mounts.sh
Is there some "hidden" Command to force-remount or force-rescan of the Host Share and (re)mount it inside the LXC Container without having to first stop it then start it again ?
I then bind-mount (
bind or rbind) inside the LXC Container in the Form of
Code:
lxc.mount.entry: /mnt/<container_name> data/ none rbind,create=dir 0 0
I devised my own little Script (NOT specific to Proxmox VE, also used on general-purpose Debian/Ubuntu/Fedora/etc) to fix NFS/CIFS-Samba/FUSE Mountpoints that end up being stale (as well as their
rbind/bind Descendants) usinghttps://github.com/luckylinux/fix-stale-handle
However, for Proxmox VE and LXC Containers, it doesn't really work, because even remounting the Host Mountpoint at
/mnt/<container_name>(and fixing the Issue from the Host point of View) doesn't actually fix the Issue in the LXC Container. The Share inside the LXC Container stays empty.
Neither does rebooting the LXC Container IIRC. I believe the only "Solution" that works is first stopping the LXC Container, wait a bit, then start the LXC Container again.
I tried some Things in this little Script here to analyse which are the LXC Mountpoints that might depend on NFS/CIFS/etc Shares, but no actual implementation yet:
https://github.com/luckylinux/fix-stale-handle/blob/main/list-pve-mounts.sh
Is there some "hidden" Command to force-remount or force-rescan of the Host Share and (re)mount it inside the LXC Container without having to first stop it then start it again ?
Last edited: