2.6.24-rc3 unable to mount something which should use nohide
Subsystems (2)
NFS server "paris" (some 2.6.18 based kernel):
[root@paris ~]# mount | grep storage /dev/mapper/StorageVG01-LogVol00 on /export/storage type ext3 (rw) /dev/mapper/KernelVG01-LogVol00 on /export/storage/kernel type ext3 (rw) [root@paris ~]# cat /etc/exports
/export/storage *(rw,sync,all_squash,anonuid=500,anongid=500)
/export/storage/kernel *(rw,sync,all_squash,anonuid=500,anongid=500,nohide)
On my clients x86_64 running an almost clean-from-git 2.6.24-rc3 kernel:
[root@dhcp231-145 ~]# mount -o noatime paris:/export/storage /storage [root@dhcp231-145 ~]# ls /storage/kernel
ls: cannot access /storage/kernel: Stale NFS file handle
(notice /storage/kernel should be triggering that nohide mount for /export/storage/kernel) so I figured maybe that automatic nohide stuff was broken. I'll try by hand:
[root@dhcp231-145 ~]# mount paris:/export/storage/kernel /storage/kernel mount.nfs: Stale NFS file handle
Same thing. Nothing in dmesg or /var/log/messages. I know this worked not long ago....
-Eric
A message that is not in the archive (sent off-list or not yet received): 1196354699.2912.57.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/[email protected]
Quoted 19 lines · Eric Paris
NFS server "paris" (some 2.6.18 based kernel):
[root@paris ~]# mount | grep storage
/dev/mapper/StorageVG01-LogVol00on /export/storage type ext3 (rw)/dev/mapper/KernelVG01-LogVol00on /export/storage/kernel type ext3 (rw) [root@paris ~]# cat/etc/exports
/export/storage *(rw,sync,all_squash,anonuid=500,anongid=500)
/export/storage/kernel *(rw,sync,all_squash,anonuid=500,anongid=500,nohide)On my clients
x86_64running an almost clean-from-git 2.6.24-rc3 kernel:[root@dhcp231-145 ~]# mount -o noatime paris:/export/storage /storage [root@dhcp231-145 ~]# ls /storage/kernel
ls: cannot access /storage/kernel: Stale NFS file handle(notice /storage/kernel should be triggering that nohide mount for /export/storage/kernel) so I figured maybe that automatic nohide stuff was broken. I'll try by hand:
Quoted 5 lines
[root@dhcp231-145 ~]# mount paris:/export/storage/kernel /storage/kernel mount.nfs: Stale NFS file handle
Same thing. Nothing in dmesg or
/var/log/messages. I know this worked not long ago....
Yep. I think the following patch ought to fix it.
Cheers
Trond
commit 72e40add4adad50613083f1fda117fd74aa875ac
Author: Trond Myklebust <[email protected]> Date: Thu Nov 29 12:39:46 2007 -0500
NFS: Fix NFS mountpoint crossing...
The check that was added to nfs_xdev_get_sb() to work around broken servers, works fine for NFSv2, but causes mountpoint crossing on NFSv3 to always return ESTALE.
fs/nfs/super.c +1 -1
@@ -1475,7 +1475,7 @@ static int nfs_xdev_get_sb(struct file_system_type *fs_type, int flags, error =PTR_ERR (mntroot); goto error_splat_super; } -if (mntroot->d_inode->i_op != &nfs_dir_inode_operations) { +if (mntroot->d_inode->i_op != server->nfs_client->rpc_ops->dir_inode_ops) {dput (mntroot); error = -ESTALE ; goto error_splat_super;
A message that is not in the archive (sent off-list or not yet received): 1196358095.7808.24.camel-rJ7iovZKK19ZJLDQqaL3InhyD016LWXt@public.gmane.org
Quoted 5 lines · Trond Myklebust
Quoted 4 lines · Eric Paris
[root@dhcp231-145 ~]# mount paris:/export/storage/kernel /storage/kernel mount.nfs: Stale NFS file handle
Quoted 7 lines
Quoted 2 lines
Same thing. Nothing in dmesg or
/var/log/messages. I know this worked not long ago....Yep. I think the following patch ought to fix it.
Cheers
Trond
Worked like a charm, thanks!
-Eric