Symas employee?Sign in

← Knowledge Base

Reference

Using slaptest

slaptest functionality is useful to check the slapd configuration to see if slapd.conf or the slapd-config backend conform to the general or backend-specific rules. 

In the case of the static configuration (slapd.conf) it is recommended to run it after any change to the configuration before attempting to restart slapd.

Syntax: 

slaptest {-f slapd.conf | -F slapd.d}
  • The slaptest command is used for confirming the validity of a slapd configuration file or directory
  • slaptest may also be used to convert a static slapd configuration file (slapd.conf) to dynamic configuration (cn=config)
Option Description

-f slapd.conf 

-F slapd.d

If both options are specified the slapd.conf is converted to the config directory
-u Perform a dry-run, which skips checking for the presence of an actual database
-v Verbose mode
-Q Quiet mode. Returns 0 for success, any other number for failure

Examples:

Test the validity of a slapd.conf file, ignoring missing databases:

slaptest -f slapd.conf -u

Convert static configuration to dynamic configuration:

mkdir slapd.d
slaptest -f slapd.conf -F slapd.d

slaptest Man Page