Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!sdd.hp.com!samsung!munnari.oz.au!brolga!lingua.cltr.uq.OZ.AU!root From: root@lingua.cltr.uq.OZ.AU (Hulk Hogan) Newsgroups: comp.protocols.nfs Subject: Re: Wanted: newgrp(1).exe for DOS under PC-NFS. Keywords: chgrp, PC-NFS Message-ID: <1991Feb5.025005.27513@lingua.cltr.uq.OZ.AU> Date: 5 Feb 91 02:50:05 GMT References: <1991Feb1.011142.10895@lingua.cltr.uq.OZ.AU> <4135@eastapps.East.Sun.COM> Distribution: comp Organization: Centre for Language Teaching and Research, Uni of Queensland, AUSTRALIA. Lines: 55 Previously, geoff@hinode.East.Sun.COM (Geoff Arnold @ Sun BOS - R.H. coast near the top) wrote: >Quoth root@lingua.cltr.uq.OZ.AU (Hulk Hogan) (in <1991Feb1.011142.10895@lingua.cltr.uq.OZ.AU>): >#Unix hosts allow user's to be members of more than one group at one time. >#The "primary group" is the one in the /etc/passwd file, unless a newgrp(1) >#is executed. PC-NFS identifies a user by keeping a uid and a single gid. >#What I'm after is a DOS command which would allow a PC-NFS user to change >#their gid to a valid group on the NFS host. Anyone have one? >#Situation: PC-NFS'd user accessing NFS files from a Sun host in the DOS >#environment. He can't access some data from his PC because PC-NFS only keeps >#his primary gid, and it one of his secondary gids which is the gid of the >#data and which allows him access when he is logged on the NFS host. >#Making his primary gid the same as the data is not a good solution. >I presume that you're not running NIS (a.k.a. YP), since if you were, >and the "group.byname" map was set up correctly, the user would belong >to all the appropriate groups. You'd still need a "newgrp" command to >change the primary group to affect the group for newly-created files. >You can check what groups you're in by executing NET NAME. [...] [...] > You are logged in as nfstest, with UID 1079 and GID 9. > You are also a member of groups : > 760 750 740 790 780 770 720 710 The PC-NFS server is not running YP, and I'd like to keep it that way! :-) The output of a "net name" command shows that there is a single uid and gid. No mention of secondary groups... This sounds like you only get the secondary groups if you run YP. Oh no, say it aint so! Geoff, will newer versions of PC-NFS support 1. BIND as an option rather than YP. (After a recent query, I now know that I can get YP to run BIND, but I don't want to run YP! :-) 2. multiple groups in the DOS environment (without requiring YP). Although I have Suns here, and so at last resort I can turn on YP, people running NFS from non-sun servers don't have this luxury, do they? The newgrp.exe I described (and hoped for) would solve the problem without having to run YP. Admittedly, it wouldn't be as elegant, but it would avoid YP. It (newgrp.exe) would modify PC-NFS's *single* gid, so that the user could do a "newgroup secondarygrp", then access the data, and then a "newgrp primarygrp" to restore the original grp. Sounds like a job for a BAT file, Robin... [good news about bugfix deleted] /\ndy -- Andrew M. Jones, Systems Programmer, Internet: andy@lingua.cltr.uq.oz.au Centre for Lang. Teaching & Research, Phone (Australia): (07) 365 6915 University of Queensland, St. Lucia, Phone (World): +61 7 365 6915 Brisbane, Qld. AUSTRALIA 4072 Fax: +61 7 365 7077 "No matter what hits the fan, it's never distributed evenly....."