2008-02-12 19:41:31

by Pascal A. Dupuis

[permalink] [raw]
Subject: [NFS] Mapping ?

Hello,

next batch of problems.
Server setup: I created a /srv/nfsv4 dir, then mounted 3 dir there
using the bind option: "/backup on /srv/nfsv4/backup type bind
(rw,bind)" and so on. The /etc/exports contains ONE dir:
/srv/nfsv4 192.168.1.2(root_squash,rw,sync,fsid=0,crossmnt,subtree_check)

rpc.imapd running, /etc/idmapd.conf minimalistic as explained in the
nfs-howto

On the client side, mounting immediatly results in the following
message: rpc.idmapd[3299]: nss_getpwnam: name '0' does not map into domain 'localdomain'

Then,
`ls -al the_mounted_dir`
drwxr-xr-x 7 nobody nogroup 4096 2007-11-28 10:07 backup
So far so good, but ...
`ls -al the_mounted_dir/backup`
kernel: fsid 0:13: expected fileid 0x2, got 0x802a

The file /etc/nsswitch.conf contains "passwd: compat"

Both server and client running Debian testing, with the package as
nfs-kernel-server/lenny uptodate 1:1.1.1-12
Kernel is 2.6.24.2.

Any idea ?

While at the subject, is there a simple way to map UID x on the server
onto UID y on the client ?

TIA

Pascal Dupuis

--


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs
_______________________________________________
Please note that [email protected] is being discontinued.
Please subscribe to [email protected] instead.
http://vger.kernel.org/vger-lists.html#linux-nfs



2008-02-13 16:05:07

by Kevin Coffman

[permalink] [raw]
Subject: Re: [NFS] Mapping ?

On Feb 12, 2008 2:40 PM, Pascal A. Dupuis <[email protected]> wrote:
> Hello,
>
> next batch of problems.
> Server setup: I created a /srv/nfsv4 dir, then mounted 3 dir there
> using the bind option: "/backup on /srv/nfsv4/backup type bind
> (rw,bind)" and so on. The /etc/exports contains ONE dir:
> /srv/nfsv4 192.168.1.2(root_squash,rw,sync,fsid=0,crossmnt,subtree_check)
>
> rpc.imapd running, /etc/idmapd.conf minimalistic as explained in the
> nfs-howto
>
> On the client side, mounting immediatly results in the following
> message: rpc.idmapd[3299]: nss_getpwnam: name '0' does not map into domain 'localdomain'

If that message is literally what you saw, it indicates that
/etc/idmapd.conf is not configured correctly. (Probably on the client
and the server.)

> Then,
> `ls -al the_mounted_dir`
> drwxr-xr-x 7 nobody nogroup 4096 2007-11-28 10:07 backup
> So far so good, but ...
> `ls -al the_mounted_dir/backup`
> kernel: fsid 0:13: expected fileid 0x2, got 0x802a

I can't tell you anything about this.

> The file /etc/nsswitch.conf contains "passwd: compat"
>
> Both server and client running Debian testing, with the package as
> nfs-kernel-server/lenny uptodate 1:1.1.1-12
> Kernel is 2.6.24.2.
>
> Any idea ?
>
> While at the subject, is there a simple way to map UID x on the server
> onto UID y on the client ?

NFSv4 uses names, not UIDs, on the wire. So, while what you are
asking for is probably possible, it would require asymmetrical
mappings between the client and server.

K.C.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs
_______________________________________________
Please note that [email protected] is being discontinued.
Please subscribe to [email protected] instead.
http://vger.kernel.org/vger-lists.html#linux-nfs