linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Simon Kirby <sim@hostway.ca>
To: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: linux-nfs@vger.kernel.org
Subject: Re: [PATCH 4/4] NFSv4: Send unmapped uid/gids to the server when using auth_sys
Date: Tue, 4 Jan 2011 13:43:34 -0800	[thread overview]
Message-ID: <20110104214334.GI27727@hostway.ca> (raw)
In-Reply-To: <1294176792.5896.22.camel@heimdal.trondhjem.org>

On Tue, Jan 04, 2011 at 04:33:12PM -0500, Trond Myklebust wrote:

> On Tue, 2011-01-04 at 13:25 -0800, Simon Kirby wrote: 
> > I finally got around to setting up idmapd properly with libnss-mysql, and
> > in doing so, I forgot that I had enabled nfs4_disable_idmapping=Y with
> > this patch applied.  With this option set on the client, and the server
> > set up normally, I get EINVAL from chown's fchowna():
> > 
> > # chown testuser:testuser test
> > chown: changing ownership of `test': Invalid argument
> > # echo N > /sys/module/nfs/parameters/nfs4_disable_idmapping
> > # chown testuser:testuser test
> > #
> > 
> > This happened on 2.6.37-rc5-git4, but I just reproduced it with
> > 2.6.37-rc8-git5 as well.  The server idmapd logs:
> > 
> > rpc.idmapd[2987]: nss_getpwnam: name '1009999' does not map into domain 'localdomain'
> > rpc.idmapd[2987]:  Server: (user) name "1009999" -> id "65534"
> > rpc.idmapd[2987]: nfsdcb: authbuf=10.10.52.0/24 authtype=group
> > rpc.idmapd[2987]:  Server: (group) name "1009999" -> id "65534"
> > 
> > (1009999 is the current uid/gid here.)
> > 
> > I think you meant for this to fall back automatically, right?
> 
> Did you remember to apply the patch 'NFSv4: Propagate the error
> NFS4ERR_BADOWNER to nfs4_do_setattr'?

Yes, that patch is applied as part of the series. 

The -EINVAL is going back to userland's fchownat().  I expected
to see the "Reenabling the idmapper" printk() from within
nfs4_handle_exception(), but this didn't seem to happen.

Simon-

  reply	other threads:[~2011-01-04 21:43 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-30  2:57 [PATCH 0/4] Allow the admin to turn off NFSv4 uid/gid mapping Trond Myklebust
2010-11-30  2:57 ` [PATCH 1/4] NFSv4: If the server sends us a numeric uid/gid then accept it Trond Myklebust
2010-11-30  2:57   ` [PATCH 2/4] NFSv4: Send unmapped uid/gids to the server if the idmapper fails Trond Myklebust
2010-11-30  2:57     ` [PATCH 3/4] NFSv4: cleanup idmapper functions to take an nfs_server argument Trond Myklebust
2010-11-30  2:57       ` [PATCH 4/4] NFSv4: Send unmapped uid/gids to the server when using auth_sys Trond Myklebust
2010-11-30  9:44         ` Boaz Harrosh
2010-11-30 13:17           ` Trond Myklebust
2010-11-30 16:02             ` Boaz Harrosh
2011-01-04 21:25         ` Simon Kirby
2011-01-04 21:33           ` Trond Myklebust
2011-01-04 21:43             ` Simon Kirby [this message]
2011-01-04 21:50               ` Trond Myklebust
2011-01-04 21:57                 ` Dr. J. Bruce Fields
2011-01-04 21:59                   ` Trond Myklebust
2011-01-04 23:18                     ` Dr. J. Bruce Fields
2011-01-04 23:23                     ` [PATCH 1/4] nfsd4: name->id mapping should fail with BADOWNER not BADNAME J. Bruce Fields
2011-01-04 23:23                     ` [PATCH 2/4] nfsd4: move idmap and acl header files into fs/nfsd J. Bruce Fields
2011-01-04 23:23                     ` [PATCH 3/4] nfsd4: remove outdated pathname-comments J. Bruce Fields
2011-01-04 23:23                     ` [PATCH 4/4] nfsd4: return nfs errno from name_to_id functions J. Bruce Fields
2010-11-30  3:15 ` [PATCH 0/4] Allow the admin to turn off NFSv4 uid/gid mapping Jim Rees
2010-11-30  3:24   ` Trond Myklebust

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=20110104214334.GI27727@hostway.ca \
    --to=sim@hostway.ca \
    --cc=Trond.Myklebust@netapp.com \
    --cc=linux-nfs@vger.kernel.org \
    /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 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).