Subject: Re: nfs bug [wrong group id in created files]
To: None <christos@deshaw.com>
From: None <Jarle.F.Greipsland@idt.unit.no>
List: current-users
Date: 04/16/1994 01:41:17
Christos Zoulas <christos@deshaw.com> writes:
> It seems to me like files created on nfs mounted directory don't have
> the correct group id set:

Strange.  Here it works fine.

% cd /home/kubben/tmp
% whoami
jarle
% groups
wheel wheel operator users
% cd /home/kubben/tmp
% df .
Filesystem                       1K-blocks    Used   Avail Capacity  Mounted on
kubben.idt.unit.no:/home/kubben     194502  146930   28121    84%    /home/kubben
% host -t hinfo kubben
kubben.idt.unit.no  	CNAME	kubben.ed.unit.no
kubben.ed.unit.no   	HINFO	PC-486/33	386BSD
% ls -lgd .
drwxr-xr-x  2 jarle  users  512 Apr 16 01:03 ./
% touch users
% chgrp wheel .; touch wheel
% chgrp operator .; touch operator
% ls -lag
total 1
drwxr-xr-x   2 jarle  operator  512 Apr 16 01:09 ./
drwxr-xr-x  12 root   wheel     512 Apr 16 01:03 ../
-rw-r--r--   1 jarle  operator    0 Apr 16 01:09 operator
-rw-r--r--   1 jarle  users       0 Apr 16 01:09 users
-rw-r--r--   1 jarle  wheel       0 Apr 16 01:09 wheel
% exit

Stop the press!!

I discovered that when I tried the same stuff on an amd-mounted directory
(from a Sun4 w/SunOS 4.1.3) I saw the same results that you described,
i.e. the new files always got the primary group gid.  However, if I did a
chmod g+s . on the SunOS side the new files would track the directory gid
(from the NetBSD machine).  Seems like the NFS-servers' gid semantics are
applied, not the client's.  I don't know enough about NFS to tell if this
is the expected behavior or not......

					-jarle
----
"We're thinking about upgrading from SunOS 4.1.1 to SunOS 3.5."
				-- Henry Spencer



------------------------------------------------------------------------------