Page 1 of 1

NFS seems artifically limited

Posted: 18 Sep 2021, 10:44
by ruk
Hi,

NFS on these devices through the UI seems to be incredibly limited, I have init'd my new F4-210 device with 4.2.15 (which broke halfway through and whatever i've worked through that).

Now when using NFS I cannot find a reasonable way setup both rw and ro for separate hosts on the same share with TOS nor can I configure squash options?

I am trying to migrate from an existing setup on a QNAP nas to this Terra F4-210

Figured i'd ask here before I return this nas for something else, to see if i'm just not seeing the option.

I am looking to configure on a single share
- * ro access
- host 1, host 2, host 3 r/w squash_all anongid/uid

I took a look at /etc/base/nasdb which holds settings and seems to be used to generate /etc/exports but while i could insert records ok, neither the new hosts nor squash settings were made out to /etc/exports on nfs service restart

It seem like this is artificially limited in the implementation and if so this NAS is not fit for purpose for me.

Further to this i've been documenting my experience with this product here https://www.mameau.com/linux/nas/

fwiw cifs is not what i am looking for in this case, looking for 1:1 nfs drop in

If someone could advise that'd be great, thanks

Re: NFS seems artifically limited

Posted: 18 Sep 2021, 11:30
by TMroy
Currently we do not have nfs permission control on UI that meets your need, we will add such feature in future releases, to configure your custom nfs permission, now You can modify the startup script in /etc/init.d/nfs, for example:rpc.mountd -f your's-config-exports-file

Re: NFS seems artifically limited

Posted: 18 Sep 2021, 13:01
by ruk
Thank you for the prompt reply.

I ended up creating /etc/exports.d/custom.exports as per exportfs(8) man pages to add my required functionality without hacking up the service script. I'll drop some notes below to help out others while the ui is extended.

Content of custom.exports

Code: Select all

# cat /etc/exports.d/custom.exports 
"/mnt/md0/share" host1ip(rw,nohide,async,no_subtree_check,insecure,all_squash,anonuid=1000,anongid=100)
"/mnt/md0/share" host2ip(rw,nohide,async,no_subtree_check,insecure,all_squash,anonuid=1000,anongid=100)
"/mnt/md0/share" host3ip(rw,nohide,async,no_subtree_check,insecure,all_squash,anonuid=1000,anongid=100)
And the content of /etc/exports as per boot config

Code: Select all

# cat /etc/exports
"/mnt/md0/share" *(ro,async,insecure,no_subtree_check,no_root_squash)
valid exports are now listed for all, while maintaining support for configuration of /etc/exports through GUI

Code: Select all

# exportfs -s
/mnt/md0/share  host1ip(rw,async,wdelay,nohide,insecure,root_squash,all_squash,no_subtree_check,anonuid=1000,anongid=100,sec=sys,rw,insecure,root_squash,all_squash)
/mnt/md0/share  host2ip(rw,async,wdelay,nohide,insecure,root_squash,all_squash,no_subtree_check,anonuid=1000,anongid=100,sec=sys,rw,insecure,root_squash,all_squash)
/mnt/md0/share  host3ip(rw,async,wdelay,nohide,insecure,root_squash,all_squash,no_subtree_check,anonuid=1000,anongid=100,sec=sys,rw,insecure,root_squash,all_squash)
/mnt/md0/share  *(ro,async,wdelay,insecure,no_root_squash,no_subtree_check,sec=sys,ro,insecure,no_root_squash,no_all_squash)