• Contact Us
  • Home
  • Installation
  • Best Practices

Database Schema Best Practices

Written by Maryanne Normann

Updated at September 10th, 2024

  • Quick Start
  • Installation
    Best Practices Configuration Troubleshooting Design Performance Platform
  • Maintenance
    Releases Upgrade
  • Reference
+ More

Table of Contents

Do not modify standard schemas Separate custom schemas from standard schemas Symas OpenLDAP 2.5+ ppolicy slapadd: Schema Checking and Value Checking Schema management

Date: 11-04-2022, Updated 3/6/2024 Ryan Conover

Do not modify standard schemas

The standard schema files in /opt/symas/etc/openldap/schema are overwritten during upgrades of OpenLDAP and any changes made will be lost. Instead, all changes should be made in custom .schema files.

Separate custom schemas from standard schemas

Custom schemas should be stored in a separate folder from the standard schema files. Separating schemas will ensure the custom ones aren't deleted/overwritten during OpenLDAP upgrades. We recommend storing custom schemas in the following path:

Unix/Linux: /opt/symas/etc/openldap/local-schema

Symas OpenLDAP 2.5+ ppolicy

The ppolicy schema does not have to be loaded in the slapd.conf as the definitions are now build into the module.

slapadd: Schema Checking and Value Checking

When utilizing slapadd to load data, it is a good practice to turn schema checking and value checking on. This takes longer than just using the -q flag for slapadd, but it will save you a headache in the long run if it finds any errors with your data.  

Usage: 

slapadd -f slapd.conf -b dc=example,dc=com -l /path/to/example.ldif -o schema-check=yes -o value-check=yes

Schema management

It is essential to maintain consistency to ensure that all directory entries are structured in a uniform manner. Ensure each of the LDAP server instances are running the same schema definitions.  It is also important to limit the number of administrators who have permission to modify schemas.

Copyright © 2020-2024 Symas Corporation. All rights reserved.
schema best practices

Was this article helpful?

Yes
No
Give feedback about this article

Related Articles

  • Don't Use Too Many Master Servers
  • OpenLDAP Best Practices Summary
  • Can OpenLDAP Connect to Other Directories?
  • Symas Blog RSS Feed
  • Symas on Facebook
  • Symas on Twitter
  • Symas Blog
  • Symas on LinkedIn
  • Symas YouTube Channel

Copyright © 2023, Symas Corporation. All rights reserved. Privacy Statement (updated July 31, 2023)

Phone:

Main Office: +1.650.963.7601
Fax: +1.650.390.6284

Email:

Sales: sales@symas.com
Support: support@symas.com

Office Hours:

8:00 AM - 5:00 PM ET

Office Location:

Symas Corporation
PO Box 391
Grand Junction, CO 81507 USA

Expand