Code: Select all
/ 192.168.0.2/32(rw,fsid=0,no_root_squash,nohide,no_subtree_check)
/storage 192.168.0.2/32(rw,no_root_squash,nohide,no_subtree_check)
/storage2 192.168.0.2/32(rw,no_root_squash,nohide,no_subtree_check)
In order for it to work, the mount points all have to be exported. I think the fsid=0 is necessary on the parent export for those filesystem mappings, the nohide will allow it to show contents of mounted filesystems without the client having to mount them explicitly, and the no_subtree_check eliminates some overhead.
The no_root_squash makes it so it allows root to access the filesystems as root. Otherwise, it's a "nobody" type permission on access and created files. The biggest consequence (and the point) is that you can't copy SUID files without no_root_squash, which doesn't suit my purposes.
Anyway, the point is that I can now just
Code: Select all
mount -t nfs hostname:/ /mnt/whatever