svn commit: r197298 - head/sbin/mount_nfs

Rick Macklem rmacklem at uoguelph.ca
Sun Sep 20 22:49:31 UTC 2009



On Sun, 20 Sep 2009, M. Warner Losh wrote:

> In message: <Pine.GSO.4.63.0909201722330.22125 at muncher.cs.uoguelph.ca>
>            Rick Macklem <rmacklem at uoguelph.ca> writes:
> :
> :
> : On Sat, 19 Sep 2009, M. Warner Losh wrote:
> :
> : > :
> : > : Hmm, it might actually be nice to be able to change those at some point
> : > : as well.  I have looked at this in the past and it is quite deeply
> : > : buried in libc. :-/
> : >
> : > What's the benefit for forcing a tcp connection for the portmapper
> : > RPCs?  They just happen once at startup...
> : >
Just fyi, I just looked at what the "competition" does and was a
bit surprised at what I found:

Linux (not really current system):
- starts out talking to Portmapper over TCP and gets a dump of the
   other machine's portmap list, then switches to UDP to get the port#s
   for Mount and NFS, even if "tcp" was specified on the mount.
- Uses UDP for both Mount and NFS by default, but switches to using
   TCP for both when "tcp" is specified.
(As noted, this was a rather old Linux system, so I wouldn't be
  surprised if this has changed/is different for other distros.)

Solaris10:
- Always uses UDP for Portmapper and Mount, no matter what is specified
   on the mount command.
- Uses TCP for NFS by default of UDP if "proto=udp" is specified as a
   mount option.

I was surprised that Solaris10 did this.

I've also noticed that the "mntudp" option doesn't do what the man
page says it does. The man page indicates that it forces the use of
UDP for Mount, even when TCP is used for NFS (like Solaris10 does
by default). However, the current mount_nfs.c switches to UDP for
both Mount and NFS when "mntudp" is specified. (It was changed to
that behaviour by r180435.

It would be nice to have it so that a default mount without
"udp" nor "tcp" specified doesn't create the unusable mount
point for a server that is UDP only, as reported by the email
to freebsd-stable on Sep. 11 with subject "NFS issues on 8.0-BETA4.
r197298 did that, but made it "less Solaris10 compatible".

I tend to like being Solaris compatible, but I'm not sure if that
makes sense for this? rick





More information about the svn-src-head mailing list