how to ldapsearch user info ?

i want to get all userid and tel number from the ldap database ,how to write the command ,thanks for you !
[113 byte] By [robote] at [2007-11-26 11:49:42]
# 1

Hi,

I suggest that you search the internet for any number of guides on using ldapsearch and writing queries like this.

Given that I don't know which attribute you store the telephone number in for your site, it is hard to provide a definite answer... in general it would be something like:

ldapsearch -h <directory server> -b <organisation base> -D "cn=directory manager" -w <directory manager password> '(|(uid=*)(telephone=*))' uid telephone

Regards,

Shane.

shane_hjorth at 2007-7-7 12:03:18 > top of Java-index,E-Mail, Calendar, & Collaboration,Sun Java System Messaging Server...