Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

We've just linked one of our Linux host to LDAP and ActiveDirectory. Now I'm trying to check how I get list of users and their details from within the Linux side.

share|improve this question
add comment

4 Answers

You can achieve that by either typing in

getent passwd |less

or performing a LDAP search, such as

ldapsearch -x -LLL uid=*

(assuming that the bind DN and credentials are set in the ldap.conf file or you have read access to AD in other ways).

share|improve this answer
add comment

If you want to check if your Linux sees the POSIX entries from a LDAP server, use

getent passwd

The output should display entries both from local /etc/passwd and LDAP server. If you are wondering how to get to the point, when there's something to check, this may prove to be a good starting point.

share|improve this answer
add comment

Linux usually uses PAM for its authentication needs. It's an open architecture, so you can use the pam_ldap module to use LDAP on Linux.

share|improve this answer
add comment

Use the ldapsearch command line tool to query the directory server for information. For more information, see "LDAP: Mastering ldapsearch".

share|improve this answer
add comment

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.