[NCLUG] NFS question

Michael Dwyer mdwyer at sixthdimension.com
Thu Sep 27 15:36:32 MDT 2001


I think he's pretty much got it hit.  Oddly, SOFT mounting it meant to
stop your machine from hanging trying to contact a dead NFS server.
But it seems to be accepted that hung servers is less of a problem
than the wierdness that writing to a dead NFS host causes.

I THINK it may be because the write system call succeeds (it writes
to cache) then dies later.  So you THINK you have written your file
and everything is happy, when that is not the case...

File locking surely gets stranger, as well.  Anyway the FAQ says:

-=-=-=-=-
There are some options you should consider adding at once. They govern
the way the NFS client handles a server crash or network outage. One of
the cool things about NFS is that it can handle this gracefully. If you
set up the clients right. There are two distinct failure modes:

soft
If a file request fails, the NFS client will report an error to the
process on the client machine requesting the file access. Some programs
can handle this with composure, most won't. We do not recommend using
this setting; it is a recipe for corrupted files and lost data. You
should especially not use this for mail disks --- if you value your
mail, that is.

hard
The program accessing a file on a NFS mounted file system will hang when
the server crashes. The process cannot be interrupted or killed (except
by a "sure kill") unless you also specify intr. When the NFS server is
back online the program will continue undisturbed from where it was. We
recommend using hard, intr on all NFS mounted file systems.
-=-=-=-=-

Interesting to note that wuarchive used to allow you to NFS their
archive.
They suggested that you do so with a soft mount so that temporary
internet
failures wouldn't hang your machine.  Presumably, you had read-only
access
there.  One assumes that soft mounting is okay so long as you also mount
read-only.


----- Original Message -----
From: <quent at pobox.com>
> I don't know how pervasive it is, but it used to be that software,
even
> vendor supplied /bin kinds of things, didn't check the return status
of
> the "write" system call. Authors assumed that if a write failed it was
due
> to hardware problems and the kernel would balk before their code would
> sense it.  With soft NFS mounts those kinds of programs won't detect a
> write failure but a write failure on a hard mount hangs your program.
>
> There's got to be a better reason than that and I have to wonder
> why the feature exists if it's so evil.
>
> Quent
>
> On Thu, Sep 27, 2001 at 01:23:26PM -0600, Mike Loseke wrote:
> >
> >  I'd like to hear some first-hand experiences about people using the
> > "-soft" option when mounting NFS mounts. Man pages in Linux, Solaris
and
> > HP-UX all discourage its use with no real reason. Opinionated Sun
employees
> > call it evil. Have you ever seen any issues arise from its use? Ever
solve
> > any problem with it? Ever lose any data with it?
> >
> > --
> >                   | If a packet hits a pocket on a socket on a port,
> >    Mike Loseke    | and the bus is interrupted as a very last
resort,
> >  mike at verinet.com | and the address of the memory makes your fd0
abort,
> >                   | the socket packet pocket has an error to report.
> > _______________________________________________
> > NCLUG mailing list
> > NCLUG at nclug.org
> > http://www.nclug.org/mailman/listinfo/nclug
> _______________________________________________
> NCLUG mailing list
> NCLUG at nclug.org
> http://www.nclug.org/mailman/listinfo/nclug
>




More information about the NCLUG mailing list