8.4.2. Converting slapd configuration

download PDF
This example assumes that the file to convert from the old slapd configuration is located at /etc/openldap/slapd.conf and the new directory for OpenLDAP configuration is located at /etc/openldap/slapd.d/.
  • Remove the contents of the new /etc/openldap/slapd.d/ directory:
    # rm -rf /etc/openldap/slapd.d/*
  • Run slaptest to check the validity of the configuration file and specify the new configuration directory:
    slaptest -f /etc/openldap/slapd.conf -F /etc/openldap/slapd.d
  • Configure permissions on the new directory:
    chown -R ldap:ldap /etc/openldap/slapd.d
    chmod -R 000 /etc/openldap/slapd.d
    chmod -R u+rwX /etc/openldap/slapd.d
  • Once the service is confirmed to be working in the new configuration directory, remove the old configuration file:
    rm -rf /etc/openldap/slapd.conf
Red Hat logoGithubRedditYoutubeTwitter


Try, buy, & sell


About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.