FS#19333 - [nfs-utils] nfs-server ignoring no_root_squash

Attached to Project: Arch Linux
Opened by Brent Pitman (bpitman0001) - Sunday, 02 May 2010, 21:17 GMT
Last edited by Tobias Powalowski (tpowa) - Friday, 19 August 2011, 10:37 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Tobias Powalowski (tpowa)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 2
Private No

Details

Description:
Upgrading from nfs-utils 1.2.1 to 1.2.2 breaks permissions of root owned files on the mounted filesystems. As I understand, the no_root_squash option in /etc/exports should allow root to mount a root owned filess and maintain permissions. From the exports man page:

Very often, it is not desirable that the root user on a client machine is also treated
as root when accessing files on the NFS server. To this end, uid 0 is normally mapped
to a different id: the so-called anonymous or nobody uid. This mode of operation
(called `root squashing') is the default, and can be turned off with no_root_squash.

My setup (with this option) has worked for the last few years. However, the upgrade to 1.2.2 broke permissions. The mount now sees nobody:nobody permissions for all root owned files in the mounted filesystem. Rolling back to 1.2.1 fixed the problem.

Additional info:
* package version(s)
nfs-utils-1.2.1-3-x86_64 => nfs-utils-1.2.2-1-x86_64 (or 1.2.2-2 - I tested both)

* config and/or log files etc.
## /etc/exports
/export/workspace 192.168.36.226(rw,no_root_squash,no_subtree_check,sync)

## /etc/fstab
192.168.32.58:/export/workspace /net/admin nfs rw,hard,intr,rsize=32768,wsize=32768 0 0

Steps to reproduce:
## steps
## 1) create mount point
## 2) demonstrate working behavior with nfs-utils 1.2.1
## 3) demonstrate upgrade to 1.2.2 changes permissions
## 4) demonstrate rollback to 1.2.1 corrects behavior

## step 1
mkdir /net/admin
ls -l /net/admin
## ownership is root:root

## step 2
pacman -U /var/cache/pacman/pkg/nfs-utils-1.2.1-3-x86_64.pkg.tar.gz
/etc/rc.d/nfs-server restart
mount /net/admin
## ownership is root:root
umount /net/admin

##step 3
pacman -U /var/cache/pacman/pkg/nfs-utils-1.2.2-1-x86_64.pkg.tar.gz
/etc/rc.d/nfs-server restart
mount /net/admin
## ownership is nobody:nobody
umount /net/admin

## step 4
pacman -U /var/cache/pacman/pkg/nfs-utils-1.2.1-3-x86_64.pkg.tar.gz
/etc/rc.d/nfs-server restart
mount /net/admin
## ownership is root:root
umount /net/admin
This task depends upon

Closed by  Tobias Powalowski (tpowa)
Friday, 19 August 2011, 10:37 GMT
Reason for closing:  Fixed
Additional comments about closing:  please reopen if still valid
Comment by Andre Herbst (moormaster) - Saturday, 12 June 2010, 14:50 GMT
I can just confirm that no_root_suash seems to be ignored in the current package
Comment by Jelle van der Waa (jelly) - Thursday, 16 June 2011, 10:02 GMT
status?

Loading...