Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

If nsswitch has passwd: files ldap set, and I do getent passwd will it first run down the /etc/passwd list and then go through every user in LDAP? That seems to be what happens. I tried it on a Red Hat server and it was scrolling thousands of lines when /etc/passwd is only 36 lines.

share|improve this question
3  
What you describe seems to me perfectly normal. When you use LDAP, getent passwd will list all users (local + ldap) –  Martin Vegter Dec 12 '13 at 18:13
    
Thanks, it's very possible that it is normal. I am fairly new to using LDAP with Linux. Previously I managed users using a configuration management utility. –  Gregg Leventhal Dec 12 '13 at 19:16

1 Answer 1

Yes, if you just say getent passwd, it will list all of the users it can find in any of the databases listed in nsswitch.

share|improve this answer
1  
only for the NSS providers that enable enumeration. For instance, with sss, you can disable enumeration for some domains. –  Stéphane Chazelas Dec 12 '13 at 22:35

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.