From owner-freebsd-questions@FreeBSD.ORG Mon May 21 21:24:12 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CD7C616A46D for ; Mon, 21 May 2007 21:24:12 +0000 (UTC) (envelope-from lreid@cs.okstate.edu) Received: from a.cs.okstate.edu (a.cs.okstate.edu [139.78.113.1]) by mx1.freebsd.org (Postfix) with ESMTP id AEEE413C483 for ; Mon, 21 May 2007 21:24:12 +0000 (UTC) (envelope-from lreid@cs.okstate.edu) Received: from [172.18.0.137] (sky_cpfw-1.tulsatech.org [70.168.226.130]) by a.cs.okstate.edu (Postfix) with ESMTP id D7590A06D9; Mon, 21 May 2007 16:24:11 -0500 (CDT) Message-ID: <46520DF5.3020808@cs.okstate.edu> Date: Mon, 21 May 2007 16:24:05 -0500 From: Reid Linnemann User-Agent: Thunderbird 2.0.0.0 (X11/20070517) MIME-Version: 1.0 To: WarrenHead References: <46520271.8080004@gmail.com> <465204AE.1070308@cs.okstate.edu> <46520AFA.1080601@gmail.com> In-Reply-To: <46520AFA.1080601@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: configuring nis X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 May 2007 21:24:12 -0000 Written by WarrenHead on 05/21/07 16:11>> > Reid Linnemann schreef: >> Written by WarrenHead on 05/21/07 15:34>> >>> Hi, >>> >>> I have been having some trouble with getting NIS working on my >>> freebsd server. Mainly because I have never before used this. >>> >>> I now have it working, but there is an odd inconsistency which I >>> don't know how to remove/update. >>> >>> I changed the gid of a user with: 'pw usermod -n sam -g 1000', but >>> this change is not reflected in the yp maps. I did recreate the maps >>> again with 'ypinit -m', but I guess that was not the trick I needed >>> to update the maps. >>> >>> So, now when I run 'ypcat passwd', I see something like this: >>> sam:*:1000:1001:Sam Genter:/home/sam:/usr/local/bin/bash >>> >>> while I also see this: 'id sam' >>> uid=1000(sam) gid=1000(sam) groups=1000(sam), 100(users) >>> >>> The difference is thus the gid. >>> >>> I can find information about updating/pushing the maps onto slave >>> servers, but not about getting changes into the maps on the sole nis >>> server I have. >>> >>> Cheers, Warren >>> >> >> pw by default works on the local /etc/passwd, not the yp passwd >> database. I suggest reading about the -y option in the manpage: >> >> -y path >> >> This sets the pathname of the database used by NIS if you are not >> sharing the information from /etc/master.passwd directly with NIS. You >> should only set this option for NIS servers. >> >> >> > Ah ofcourse. I wasn't using the default /etc/master.passwd because that > one contains way more users than I want to share among machines. > Thanks for the heads up! > > Cheers, Warren Also of interest should be the -Y option, which when used with the -y flag automatically triggers a 'make' in /var/yp.