NFS - how to tell the mount options
Rick Stevens
rstevens at vitalstream.com
Thu Apr 1 01:04:41 UTC 2004
Waldher, Travis R wrote:
>>-----Original Message-----
>>From: Rick Stevens [mailto:rstevens at vitalstream.com]
>>Sent: Wednesday, March 31, 2004 10:38 AM
>>To: Getting started with Red Hat Linux
>>Subject: Re: NFS - how to tell the mount options
>>
>>
>>Waldher, Travis R wrote:
>>
>>>I forgot where it was...
>>>
>>>Where is the file that tells me what a NFS mount used as far as
>>>options
>>>goes? nfsv2 vs v3, cache settings, etc.?
>>
>>"man nfs" will give you the available options. As far as
>>where you specify them at mount time, that's in /etc/fstab.
>>
>>
>>>If I don't manually set how I want it to mount, I don't know how to
>>>tell
>>>how it did mount.
>>
>>"mount" alone should show you which non-default options were
>>actually used. Those not displayed use the defaults shown in
>>"man nfs":
>>
>> [root at smtp-01-001 bin]# mount -l -t nfs
>> netapp2:/VIRTMAIL on /virtmail type nfs
>> (rw,tcp,hard,noac,rsize=8192,wsize=8192,
>> nfsvers=3,addr=10.24.1.4)
>>
>>The stuff not displayed use the defaults. The corresponding
>>line in /etc/fstab (wrapped for easier reading) is:
>>
>> netapp2:/VIRTMAIL /virtmail nfs \
>> rw,tcp,hard,noac,rsize=8192,wsize=8192,nfsvers=3
>>
>>Ok?
>
>
> Well... Here's the riddle.
>
> How can I tell which version of nfs is being used. The default
> according to the nfs man page is version 2. I didn't specifically say
> use nfsvers2 or 3, so it should have used 2.
>
> Then why are my nfs v3 nfs counters going up when I transfer data?
>
> Client nfs v3:
> null getattr setattr lookup access readlink
> 0 0% 31227016 5% 15363112 2% 19036511 3% 387690989 0% 228600
> 0%
> read write create mkdir symlink mknod
> 63 0% 76477074 6% 4455603 0% 102785 0% 1276273 0% 24 0%
> remove rmdir rename link readdir readdirplus
> 4114960 0% 168678 0% 10 0% 727 0% 103584 0% 0 0%
> fsstat fsinfo pathconf commit
> 1547 0% 1547 0% 0 0% 4621261 0%
>
> I have about 200 file systems mounted right now, many must be nfsv2,
> because that's all the server supports, obviously others decided to
> mount up to nfsv3. BUT, how can I tell. None of the commands you gave
> me are telling me anything, and I never specified in the fstab file
> which version of nfs to use.
If "mount" does not explicitly tell you that it's mounted as "nfsvers=3"
then it's V2. The stats show up in the V3 client data because your
_client_ is V3 (which is backwards-compatible with V2). I know, it's
weird, but that's how it goes.
----------------------------------------------------------------------
- Rick Stevens, Senior Systems Engineer rstevens at vitalstream.com -
- VitalStream, Inc. http://www.vitalstream.com -
- -
- Memory is the second thing to go, but I can't remember the first! -
----------------------------------------------------------------------
More information about the Redhat-install-list
mailing list