NFS share to unprivileged LXC doesn't work after change from VE8 to VE9

anaza

Member
Apr 22, 2023
1
0
6
Hi.
Im somewhat new to Linux and Proxmox but have managed :)
On my previous VE8 installation I managed to get NFS share to LXC container to work.
But yesterday when I did a fresh install om VE9 and restored my containers from PBS the shares don´t work anymore.

From NAS (Synology) to Proxmox host works.
I can edit the folders and view content on host.

On host, in /etc/fstab
Code:
192.168.1.220:/volume1/media /mnt/alexandria/media nfs4 defaults,_netdev 0 0
192.168.1.220:/volume1/backups /mnt/alexandria/backup nfs4 defaults,_netdev 0 0
192.168.1.220:/volume1/proxmox /mnt/alexandria/proxmox nfs4 defaults,_netdev 0 0

The .conf file for the container looks this:
Code:
arch: amd64
cores: 4
dev0: /dev/dri/renderD128
features: nesting=1
hostname: LXC
memory: 2048
mp0: /mnt/alexandria/media/,mp=/mnt/media/,ro=1
mp1: /mnt/alexandria/proxmox/,mp=/mnt/proxmox
net0: name=eth0,bridge=vmbr0,firewall=1,hwaddr=3e:ac:63:dd:6d:1a,ip=dhcp,type=veth
onboot: 1
ostype: debian
rootfs: local-lvm:vm-100-disk-0,size=20G
swap: 512
tags: media
unprivileged: 1
lxc.cgroup.devices.allow: c 226:0 rwm
lxc.cgroup.devices.allow: c 226:128 rwm
lxc.mount.entry: /dev/dri/renderD128 /dev/dri/renderD128 none bind,optional,create=file
lxc.mount.entry: /dev/dri/card1 dev/dri/card0 none bind,optional,create=file
lxc.idmap: u 0 100000 65536
lxc.idmap: g 0 100000 44
lxc.idmap: g 44 44 1
lxc.idmap: g 45 100045 62
lxc.idmap: g 107 993 1
lxc.idmap: g 108 100108 65428

In the container I can see the mountpoints in /mnt but when I try to look in the folders I get hit with "Permission denied".
This configuration did work on VE8 and after several hours of googling and testing yesterday I decided to try here if any of you can help me understand what I´m doing wrong.

On host I have RW rights to mounted folders.
UID/GUID is root/root on one folder and 101005/101005 on the others.

In LCX the it looks like I have the same permissions but I can´t go in to folder.
(The groupID of nfs_shares is 1005 and root is a member of this group)
Code:
#  2025-08-08 13:16:54  root@LXC  Cmd:12 Act:0  Dir:/mnt
$ ls -lah
total 8.0K
drwxr-xr-x  4 root root       4.0K Jul 15 12:47 .
drwxr-xr-x 18 root root       4.0K Aug  7 22:10 ..
drwxrwxrwx  1 1005 nfs_shares  148 Apr  5  2023 media
drwxrwxrwx  1 1005 nfs_shares  216 Aug  8 13:16 proxmox

I can´t figure it out why it doesn´t work anymore.... :S
 
Last edited: