All of lore.kernel.org
 help / color / mirror / Atom feed
From: James Pearson <james-p@moving-picture.com>
To: nfs@lists.sourceforge.net, autofs@linux.kernel.org
Cc: trond.myklebust@fys.uio.no
Subject: Re: Re: [autofs] Server/client mismatch over status of a mount ...
Date: Tue, 18 Feb 2003 16:57:14 +0000	[thread overview]
Message-ID: <3E5265EA.14C644F5@moving-picture.com> (raw)
In-Reply-To: 3E5120C4.9C03C7A6@moving-picture.com

I've been looking into the umount code a bit more, trying to work out
what's going on - however it appears that as rpc.mountd on the server is
contacted before the umount, then the entry in /var/lib/nfs/rmtab on the
server for the client mount is removed regardless of the success of the
umount system call ...

This means that if you attempt a umount of an NFS file system, but get
an error like 'device is busy', then if the server reboots, the client
gets 'permission denied' on the NFS file system mount point ... 

Surely this can't be right?

Fortunately, as autofs doesn't appear to attempt a umount until the
mount point is 'free', then you shouldn't have this problem - unless you
manually umount the mount point, or something goes wrong...

The man page for rpc.mountd states:

    The rmtab File
       For  every  mount  request  received  from  an NFS client,
       rpc.mountd adds an entry to the /var/state/nfs/rmtab file.
       When  receiving an unmount request, that entry is removed.
       user level part of the NFS service.

       However, this file is mostly ornamental. One,  the  client
       can  continue  to  use  the file handle even after calling
       rpc.mountd 's UMOUNT  procedure.  And  two,  if  a  client
       reboots  without notifying rpc.mountd , a stale entry will
       remain in rmtab.

which appears to suggest that having 'stale' entries in rmtab is not a
problem, which seems to suggest that dropping the RPC umount call
wouldn't cause any adverse effects - and also stop the 'permission
denied' my problem ...

James Pearson
 

James Pearson wrote:
> 
> What would be the side effects of dropping the RPC call? I guess the
> rpc.mountd on the server will never get a umount request - will this
> cause problems with the client autofs repeatedly mounting/umounting file
> systems from the server?
> 
> With my particular problem, there was nothing in the system log on the
> client to indicate the the NFS filesystem couldn't be umounted - i.e.
> under what circumstances could umount think it's OK to umount, but the
> actual umount fails - if I try to umount an NFS filesystem that has open
> resources, it get a 'device is busy' error.
> 
> Thanks
> 
> James Pearson
> 
> Trond Myklebust wrote:
> >
> > >>>>> " " == James Pearson <james-p@moving-picture.com> writes:
> >
> >      > So, is there a possible workround?  Thanks
> >
> > Workaround: drop the entire RPC call. Failing that, you have a choice
> > of races...
> >
> > A real fix would involve teaching the knfsd kernel processes to do
> > upcalls to userland in order to find out if a client is authorized or
> > not. This is feasible in 2.5.x, but not in 2.4.x (as the latter lacks
> > the machinery for doing upcalls to userland).
> >
> > Cheers,
> >   Trond
> >
> > -------------------------------------------------------
> > This sf.net email is sponsored by:ThinkGeek
> > Welcome to geek heaven.
> > http://thinkgeek.com/sf
> > _______________________________________________
> > NFS maillist  -  NFS@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/nfs
> _______________________________________________
> autofs mailing list
> autofs@linux.kernel.org
> http://linux.kernel.org/mailman/listinfo/autofs


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
NFS maillist  -  NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs

  reply	other threads:[~2003-02-18 16:57 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-17 14:06 Server/client mismatch over status of a mount James Pearson
2003-02-17 15:20 ` [autofs] " H. Peter Anvin
2003-02-17 15:50   ` Trond Myklebust
2003-02-17 15:57     ` James Pearson
2003-02-17 16:16       ` Trond Myklebust
2003-02-17 17:49         ` James Pearson
2003-02-18 16:57           ` James Pearson [this message]
2003-02-19  9:56             ` H. Peter Anvin
2003-02-19 10:16               ` Trond Myklebust
2003-02-19 13:58               ` Ion Badulescu
2003-02-19 18:16                 ` H. Peter Anvin
2003-02-20  3:20                   ` Jeremy Fitzhardinge
2003-02-20  3:26                     ` Ion Badulescu
2003-02-20  3:43                       ` Jeremy Fitzhardinge

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3E5265EA.14C644F5@moving-picture.com \
    --to=james-p@moving-picture.com \
    --cc=autofs@linux.kernel.org \
    --cc=nfs@lists.sourceforge.net \
    --cc=trond.myklebust@fys.uio.no \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.