Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Feb 2003 10:50:40 -0500
From:      Chuck Swiger <cswiger@mac.com>
Cc:        freebsd <freebsd-questions@FreeBSD.ORG>
Subject:   Re: MINUID in NIS Makefile
Message-ID:  <3E54F950.2070706@mac.com>
In-Reply-To: <200302201630.21546.ajacoutot@lphp.org>
References:  <200302201226.37661.ajacoutot@lphp.org> <20030220151739.GM13096@dan.emsphone.com> <200302201630.21546.ajacoutot@lphp.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Antoine Jacoutot wrote:
 > On Thursday 20 February 2003 16:17, Dan Nelson wrote:
[ ... ]
> The MINUID and MINGID allow to create passwd.by* only with account which UID 
> are equal or higher than MINUID and group.by* only with groups which GID are 
> equal or higher than MINGID.

20-sec% MINUID=50 

21-sec% awk -F: "{if (\$3 > $MINUID) print }" /etc/passwd 

bind:*:53:53:Bind Sandbox:/:/sbin/nologin
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/libexec/uucp/uucico
xten:*:67:67:X-10 daemon:/usr/local/xten:/sbin/nologin
pop:*:68:6:Post Office Owner:/nonexistent:/sbin/nologin
www:*:80:80:World Wide Web Owner:/nonexistent:/sbin/nologin
nobody:*:65534:65534:Unprivileged user:/nonexistent:/sbin/nologin
chuck:*:1000:1000:Charles Swiger:/home/chuck:/bin/zsh
squid:*:3128:3128:Squid Cache:/home/squid:/sbin/nologin

...or `ypcat`, or however you get a flatfile version of /etc/passwd.

>> You don't need to copy
>> /var/yp/master.passwd to edit it; just make the change and run "make".
> 
> So I would change the original /etc/master.passwd ?????? Is that OK, it looks 
> like it's not.

Use 'vipw' to edit /etc/passwd safely.

However, the point of NIS is to provide a network-based source of users 
which are in addition to the users in the local /etc/passwd database. 
On your YP/NIS master server, cd to "/var/yp" and do a make.  That will 
propogate updated versions of the passwd.foo NIS maps to the NIS clients.

-Chuck


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3E54F950.2070706>