Public bug reported:

If I specify "root_squash" as the default option for an export, and
try to except one host by specifying "no_root_squash" for just that,
it does not work. The directory is exported with root_squash for
all hosts. For example, given the following line in /etc/exports:

/s/d5  -rw,sync,no_subtree_check,root_squash 192.168.1.10
192.168.1.11(no_root_squash)

I get:

root@fs1:/etc# exportfs -ra
root@fs1:/etc# exportfs -v |fgrep /s/d5
/s/d5 
192.168.1.10(rw,wdelay,root_squash,no_subtree_check,sec=sys,rw,root_squash,no_all_squash)
/s/d5 
192.168.1.11(rw,wdelay,root_squash,no_subtree_check,sec=sys,rw,root_squash,no_all_squash)

Note that "root_squash" is specified twice for some reason in the output of
"exportfs -v". Also note that the no_root_squash for 192.168.1.11 did not
take effect.

The inverse is also true. If no_root_squash is specified as the default, then
it is impossible to export to select hosts with root_squash. For example,
given the following line in /etc/exports:

/s/d5  -rw,sync,no_subtree_check,no_root_squash 192.168.1.10
192.168.1.11(root_squash)

root@fs1:/etc# exportfs -ra
root@fs1:/etc# exportfs -v |fgrep /s/d5
/s/d5           
192.168.1.10(rw,wdelay,no_root_squash,no_subtree_check,sec=sys,rw,no_root_squash,no_all_squash)
/s/d5           
192.168.1.11(rw,wdelay,no_root_squash,no_subtree_check,sec=sys,rw,no_root_squash,no_all_squash)

Note that both hosts are getting no_root_squash.

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: nfs-kernel-server 1:1.2.8-9ubuntu12.1
ProcVersionSignature: Ubuntu 4.15.0-32.35~16.04.1-generic 4.15.18
Uname: Linux 4.15.0-32-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.18
Architecture: amd64
Date: Wed Aug 29 11:51:33 2018
SourcePackage: nfs-utils
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: nfs-utils (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug xenial

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1789687

Title:
  Exportfs ignores no_root_squash option when the default is
  root_squash, and vice versa

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/nfs-utils/+bug/1789687/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to