Slap Tools

The collection of slap tools included with OpenLDAP are provided to import and export data directly from the DB files used for supporting an OpenLDAP server.

slapadd(8c)

This tool reads LDIF entries from a file or standard input and writes the new records to a slapd database (see Table B-2).

Table B-2. Summary of slapadd command-line arguments

Option

Description

-c

Continues processing input in the event of errors.

-b suffix-n integer

Specify which database in the configuration file to use by the directory’s suffix (-b) or by its location (-n) in the slapd.conf file (the first database listed is numbered 0). These options are mutually exclusive.

-d integer

Specifies which debugging information to log. See the loglevel parameter in slapd.conf for a listing of log levels.

-f filename

Specifies which configuration file to read.

-l filename

Specifies the LDIF file to use for input. In the absence of this option, slapadd reads data from standard input.

-v

Enables verbose mode.

slapcat(8c)

This tool reads records from a slapd database and writes them to a file or standard output (see Table B-3).

Table B-3. Summary of slapcat command-line arguments

Option

Description

-c

Continues processing input in the event of errors.

-b suffix-n integer

Specify which database in the configuration file to use by the directory’s suffix (-b) or by its location (-n) in the slapd.conf file (the first database listed is numbered 0). These options are mutually exclusive. ...

Get LDAP System Administration now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.