linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* whether can NFS exports option 'nohide' work?
@ 2010-01-07  8:58 Bian Naimeng
  2010-01-08  5:02 ` J. Bruce Fields
  0 siblings, 1 reply; 3+ messages in thread
From: Bian Naimeng @ 2010-01-07  8:58 UTC (permalink / raw)
  To: linux-nfs; +Cc: Trond Myklebust, J. Bruce Fields

Hi,

I want to use this option=81C but i find it doesn't work at RHEL5.4GA a=
nd Fedora12.

My /etc/exports like this:
# cat /etc/exports
  /nfsroot/nfsv4	127.0.0.1(rw,nohide,fsid=3D0)
  /nfsroot/nfsv4/dir1	127.0.0.1(rw,nohide,crossmnt)
  /nfsroot/nfsv4/dir2	127.0.0.1(rw,nohide,crossmnt)

Then:

# mkdir /nfsroot/nfsv4/dir1/tmpdir
# echo "best wishes" > /nfsroot/nfsv4/dir1/file1
# echo "happy new year" > /nfsroot/nfsv4/dir2/file2

# service nfs restart
# mount -t nfs4 127.0.0.1:/dir2 /nfsroot/nfsv4/dir1/tmpdir
# mount -t nfs4 127.0.0.1:/dir1 /mnt

There is file2 at /nfsroot/nfsv4/dir1/tmpdir, but nothing at /mnt/tmpdi=
r.
I'm not sure i have used it correctly, and whether it really work?=20
Thanks for your help.

--=20
Best Regards
Bian


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: whether can NFS exports option 'nohide' work?
  2010-01-07  8:58 whether can NFS exports option 'nohide' work? Bian Naimeng
@ 2010-01-08  5:02 ` J. Bruce Fields
  2010-01-08  9:49   ` Bian Naimeng
  0 siblings, 1 reply; 3+ messages in thread
From: J. Bruce Fields @ 2010-01-08  5:02 UTC (permalink / raw)
  To: Bian Naimeng; +Cc: linux-nfs, Trond Myklebust

On Thu, Jan 07, 2010 at 04:58:28PM +0800, Bian Naimeng wrote:
> Hi,
>=20
> I want to use this option=EF=BC=8C but i find it doesn't work at RHEL=
5.4GA and Fedora12.
>=20
> My /etc/exports like this:
> # cat /etc/exports
>   /nfsroot/nfsv4	127.0.0.1(rw,nohide,fsid=3D0)
>   /nfsroot/nfsv4/dir1	127.0.0.1(rw,nohide,crossmnt)
>   /nfsroot/nfsv4/dir2	127.0.0.1(rw,nohide,crossmnt)
>=20
> Then:
>=20
> # mkdir /nfsroot/nfsv4/dir1/tmpdir
> # echo "best wishes" > /nfsroot/nfsv4/dir1/file1
> # echo "happy new year" > /nfsroot/nfsv4/dir2/file2
>=20
> # service nfs restart
> # mount -t nfs4 127.0.0.1:/dir2 /nfsroot/nfsv4/dir1/tmpdir
> # mount -t nfs4 127.0.0.1:/dir1 /mnt
>=20
> There is file2 at /nfsroot/nfsv4/dir1/tmpdir, but nothing at /mnt/tmp=
dir.
> I'm not sure i have used it correctly, and whether it really work?=20
> Thanks for your help.

You can't re-export nfs filesystems.

(I wonder why we aren't warning about this?)

--b.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: whether can NFS exports option 'nohide' work?
  2010-01-08  5:02 ` J. Bruce Fields
@ 2010-01-08  9:49   ` Bian Naimeng
  0 siblings, 0 replies; 3+ messages in thread
From: Bian Naimeng @ 2010-01-08  9:49 UTC (permalink / raw)
  To: J. Bruce Fields; +Cc: linux-nfs, Trond Myklebust



J. Bruce Fields =8E=CA=93=B9:
> On Thu, Jan 07, 2010 at 04:58:28PM +0800, Bian Naimeng wrote:
>> Hi,
>>
>> I want to use this option=81C but i find it doesn't work at RHEL5.4G=
A and Fedora12.
>>
>> My /etc/exports like this:
>> # cat /etc/exports
>>   /nfsroot/nfsv4	127.0.0.1(rw,nohide,fsid=3D0)
>>   /nfsroot/nfsv4/dir1	127.0.0.1(rw,nohide,crossmnt)
>>   /nfsroot/nfsv4/dir2	127.0.0.1(rw,nohide,crossmnt)
>>
>> Then:
>>
>> # mkdir /nfsroot/nfsv4/dir1/tmpdir
>> # echo "best wishes" > /nfsroot/nfsv4/dir1/file1
>> # echo "happy new year" > /nfsroot/nfsv4/dir2/file2
>>
>> # service nfs restart
>> # mount -t nfs4 127.0.0.1:/dir2 /nfsroot/nfsv4/dir1/tmpdir
>> # mount -t nfs4 127.0.0.1:/dir1 /mnt
>>
>> There is file2 at /nfsroot/nfsv4/dir1/tmpdir, but nothing at /mnt/tm=
pdir.
>> I'm not sure i have used it correctly, and whether it really work?=20
>> Thanks for your help.
>=20
> You can't re-export nfs filesystems.
>=20
> (I wonder why we aren't warning about this?)
>=20

  Though i does not mount nfs filesystem, instead by ext3 filesystem /d=
ev/hda,
  there is not anyting at /mnt/tmpdir.

  # mount /dev/hda3 /nfsroot/nfsv4/dir1/tmpdir
  # mount -t nfs4 127.0.0.1:/dir1  /mnt

  # ll /mnt/tmpdir/
    total 0

  Then, i test it at two different RHEL5.4 host.

  host1=81infs server=81j:
  # cat /etc/exports
    /nfsroot/nfsv4		host2(rw,nohide,crossmnt,fsid=3D0)
    /nfsroot/nfsv4/dir1		host2(rw,nohide,crossmnt)

  # mount /dev/hda3 /nfsroot/nfsv4/dir1/tmpdir

  host2 (nfs client):
  # mount -t nfs4 host1:/dir1 /mnt
  # ll /mnt/
    ls: /nfsv4/tmpdir: Stale NFS file handle
    total 4
    -rw-r--r-- 1 root root    0 Jan  5  2010 file1
    drwxr-xr-x 6 root root 4096 Jan  6  2010 tmpdir

  # ll /nfsv4/tmpdir
    ls: /nfsv4/tmpdir: Stale NFS file handle
    ls: /nfsv4/tmpdir: Stale NFS file handle

 Best Regards
  Bian


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-01-08  9:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-07  8:58 whether can NFS exports option 'nohide' work? Bian Naimeng
2010-01-08  5:02 ` J. Bruce Fields
2010-01-08  9:49   ` Bian Naimeng

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).