Hi.
I'm trying to set up an NFSv4 share, and everything works when setting a limit for only one network.
The /etc/exports:
Then, adding with ZFS set:
After that, I can mount using "sudo mount -t nfs4 192.168.0.2:/backups /mnt/test/" on my Linux client.
But I have a VPN network on this FreeBSD host and want to add it too.
Tried all possible combinations like:
But none works, and mountd sends "bad exports list line" errors.
So... What's the correct way to do so? Found few threads here, for example Help with zfs sharenfs and NFSv4, ZFS set sharenfs multiple hosts, but none works for me.
Or just do share for all with "sharenfs=on"? Doesn't look like a correct way...
What I'm missing here?
P.S. Also wondering why zfs-set man page has an example with the `@=` notation:
Which isn't working:
This gives the "bad exports list line '/nas/nfs/backups rw=@192.168.0.0/24': no valid entries" error.
I'm trying to set up an NFSv4 share, and everything works when setting a limit for only one network.
The /etc/exports:
Code:
V4: /nas/nfs
Then, adding with ZFS set:
Code:
# zfs set sharenfs="-network 192.168.0.0/24 -maproot=root" nas/nfs/backups
After that, I can mount using "sudo mount -t nfs4 192.168.0.2:/backups /mnt/test/" on my Linux client.
But I have a VPN network on this FreeBSD host and want to add it too.
Tried all possible combinations like:
Code:
zfs set sharenfs="-network 192.168.0.0/24 -maproot=root -network 192.168.100.0/24" nas/nfs/backups
zfs set sharenfs="192.168.0.0/24,192.168.100.0/24" nas/nfs/backups
zfs set sharenfs="network=192.168.0.0/24,network=192.168.100.0/24" nas/nfs/backups
zfs set sharenfs="-network 192.168.0.0 -mask 255.255.255.0 192.168.100.0 -mask 255.255.255.0 10.8.0.0 -mask 255.255.255.0" nas/nfs/backups
But none works, and mountd sends "bad exports list line" errors.
So... What's the correct way to do so? Found few threads here, for example Help with zfs sharenfs and NFSv4, ZFS set sharenfs multiple hosts, but none works for me.
Or just do share for all with "sharenfs=on"? Doesn't look like a correct way...
What I'm missing here?
P.S. Also wondering why zfs-set man page has an example with the `@=` notation:
Code:
# zfs set sharenfs='rw=@123.123.0.0/16:[::1],root=neo' tank/home
Which isn't working:
Code:
# zfs set sharenfs='rw=@192.168.0.0/24' nas/nfs/backups
This gives the "bad exports list line '/nas/nfs/backups rw=@192.168.0.0/24': no valid entries" error.