NIS
Matthew Gillen
me at mattgillen.net
Fri Oct 13 14:37:38 EDT 2006
Jerry Feldman wrote:
>> Does 'genent passwd' also correctly display the users?
> yes. 'getent passwd' displays the 4 password lines correctly.
> As I mentioned 'ypcat passwd ' was able to display all the password
> entries correctly. Additionally, 'ypmatch gaf passwd
Right, but ypcat and getent are different. On my machine, ypcat only prints
what's in the NIS database, while getent returns the combination of
/etc/passwd and NIS. If nsswitch doesn't have the nis lines, then ypcat would
still work as you said, but you wouldn't see your NIS users in 'getent' output.
>> If not, check your /etc/nsswitch.conf file, and make sure there is
>> entries that look like this:
>>
>> passwd: files nis
>> shadow: files nis
>> group: files nis
> /etc/nsswitch is correct.
>
> My next step is to write a short C program to use one of the getpwent(3)
> and getpwnam(3) functions.
You might also check your PAM configuration. Make sure pam_unix.so is in all
the following entries:
auth
account
password
session
Matt
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
More information about the Discuss
mailing list