LDAP command notes

Source: Internet
Author: User
Tags ldap ldapsearch

LDAPCommon commands

1. ldapadd-X-d "cn = manager, ou = xxzx, O = netcenter, Dc = ujs, Dc = Edu, Dc = cn"-w-F first. ldif

2. ldapsearch-X-B "ou = xxzx, O = netcenter, Dc = ujs, Dc = Edu, Dc = cn" '(objectclass = *)'

Ldapsearch-X-B "ou = xxzx, O = netcenter, Dc = ujs, Dc = Edu, Dc = cn" '(| (uid = *)) 'or condition Query

3. ldapsearch Data Backup

Ldapsearch-H hostip-X-B "DC = JS, Dc = Edu, Dc = cn"-d "cn = admin, Dc = ujs, Dc = Edu, dc = cn "-lll" (objectclass = *) "-W Password

For lll, see man ldapsearch, which indicates that the output is the third version of ldif.

4. ldapdelete-m-X-d "cn = manager, Dc = Edu, Dc = cn"-W "ou = xxzx, O = netcenter, Dc = JS, Dc = Edu, dc = cn"

You can use-m to delete referral. For more information, see distributed OpenLDAP directory summary.

5. When using referral, both rootdn and suffix must be consistent.

6. ldapmodify-m-X-d "cn = LDAP, Dc = ujs, Dc = Edu, Dc = cn"-w-F first. ldif

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.