13.07.2015 Views

Naming and Directory Services (DNS, NIS, and LDAP)

Naming and Directory Services (DNS, NIS, and LDAP)

Naming and Directory Services (DNS, NIS, and LDAP)

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Checking the Current Profile InformationBecome superuser or assume an equivalent role, <strong>and</strong> run ldapclient with the listoption.# ldapclient listNS_<strong>LDAP</strong>_FILE_VERSION= 2.0NS_<strong>LDAP</strong>_BINDDN= cn=proxyagent,ou=profile,dc=west,dc=example,dc=comNS_<strong>LDAP</strong>_BINDPASSWD= {NS1}4a3788e8c053424fNS_<strong>LDAP</strong>_SERVERS= 192.168.0.1, 192.168.0.10NS_<strong>LDAP</strong>_SEARCH_BASEDN= dc=west,dc=example,dc=comNS_<strong>LDAP</strong>_AUTH= simpleNS_<strong>LDAP</strong>_SEARCH_REF= TRUENS_<strong>LDAP</strong>_SEARCH_SCOPE= oneNS_<strong>LDAP</strong>_SEARCH_TIME= 30NS_<strong>LDAP</strong>_SERVER_PREF= 192.168.0.1NS_<strong>LDAP</strong>_PROFILE= pit1NS_<strong>LDAP</strong>_CREDENTIAL_LEVEL= proxyNS_<strong>LDAP</strong>_SERVICE_SEARCH_DESC= passwd:ou=people,?subNS_<strong>LDAP</strong>_SERVICE_SEARCH_DESC= group:ou=group,dc=west,dc=example,dc=com?oneNS_<strong>LDAP</strong>_BIND_TIME= 5Currently the /var/ldap files are in ASCII format. Because the files could change tobinary at some time, concatenating the files would cause problems. ldapclientlist is the supported method for accessing this information. See theldapclient(1M) man page for more information.Verifying Basic Client-Server CommunicationThe best way to show that your client is talking to the <strong>LDAP</strong> server is with theldaplist comm<strong>and</strong>. Using ldaplist with no arguments dumps all the containerson the server. This works as long as the containers exist, <strong>and</strong> do not have to bepopulated. See the ldaplist(1) man page for more information.If the first step works, you can try ldaplist passwd username or ldaplist hostshostname but if they contain lots of data you might want to pick a less populatedservice, or pipe them to head or more.Checking Server Data From a Non-Client MachineMost of the comm<strong>and</strong>s in the previous sections assume you already have created an<strong>LDAP</strong> client. If you have not created a client <strong>and</strong> want to check the data on the server,use the ldapsearch comm<strong>and</strong>. The following example lists all of the containers.# ldapsearch -h server1 -b "dc=west,dc=example,dc=com" -s one "objectclass=*"In Solaris 9 <strong>and</strong> earlier releases, the ldapsearch comm<strong>and</strong>, by default, producedoutput in a nonst<strong>and</strong>ard textual representation. The default output for ldapsearchin later Solaris releases is the industry st<strong>and</strong>ardized LDIF format that is defined byRFC-2849. All versions of ldapsearch can output LDIF format using the -L option.Chapter 13 • <strong>LDAP</strong> Troubleshooting (Reference) 191

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!