1SLAPINDEX(8C) SLAPINDEX(8C)
2
3
4
6 slapindex - Reindex entries in a SLAPD database
7
9 /usr/sbin/slapindex [-b suffix] [-c] [-d debug-level] [-f slapd.conf]
10 [-F confdir] [-g] [-n dbnum] [-o option[=value]] [-q] [-t] [-v]
11 [attr[...]]
12
14 Slapindex is used to regenerate slapd(8) indices based upon the current
15 contents of a database. It opens the given database determined by the
16 database number or suffix and updates the indices for all values of all
17 attributes of all entries. If a list of specific attributes is provided
18 on the command line, only the indices for those attributes will be re‐
19 generated. Databases configured as subordinate of this one are also
20 re-indexed, unless -g is specified.
21
22 All files eventually created by slapindex will belong to the identity
23 slapindex is run as, so make sure you either run slapindex with the
24 same identity slapd(8) will be run as (see option -u in slapd(8)), or
25 change file ownership before running slapd(8).
26
28 -b suffix
29 Use the specified suffix to determine which database to generate
30 output for. By default, the first database that supports the re‐
31 quested operation is used. The -b cannot be used in conjunction
32 with the -n option.
33
34 -c enable continue (ignore errors) mode.
35
36 -d debug-level
37 enable debugging messages as defined by the specified debug-
38 level; see slapd(8) for details.
39
40 -f slapd.conf
41 specify an alternative slapd.conf(5) file.
42
43 -F confdir
44 specify a config directory. If both -f and -F are specified,
45 the config file will be read and converted to config directory
46 format and written to the specified directory. If neither op‐
47 tion is specified, an attempt to read the default config direc‐
48 tory will be made before trying to use the default config file.
49 If a valid config directory exists then the default config file
50 is ignored.
51
52 -g disable subordinate gluing. Only the specified database will be
53 processed, and not its glued subordinates (if any).
54
55 -n dbnum
56 Generate output for the dbnum-th database listed in the configu‐
57 ration file. The config database slapd-config(5), is always the
58 first database, so use -n 0
59
60 The -n cannot be used in conjunction with the -b option.
61
62 -o option[=value]
63 Specify an option with a(n optional) value. Possible generic
64 options/values are:
65
66 syslog=<subsystems> (see `-s' in slapd(8))
67 syslog-level=<level> (see `-S' in slapd(8))
68 syslog-user=<user> (see `-l' in slapd(8))
69
70
71 -q enable quick (fewer integrity checks) mode. Performs no consis‐
72 tency checks when writing the database. Improves indexing time,
73 however the database will most likely be unusable if any errors
74 or interruptions occur.
75
76 -t enable truncate mode. Truncates (empties) an index database be‐
77 fore indexing any entries. May only be used with back-mdb.
78
79 -v enable verbose mode.
80
82 Your slapd(8) should not be running (at least, not in read-write mode)
83 when you do this to ensure consistency of the database.
84
85 This command provides ample opportunity for the user to obtain and
86 drink their favorite beverage.
87
89 To reindex your SLAPD database, give the command:
90
91 /usr/sbin/slapindex
92 To regenerate the index for only a specific attribute, e.g. "uid", give
93 the command:
94
95 /usr/sbin/slapindex uid
96
98 ldap(3), ldif(5), slapadd(8), ldapadd(1), slapd(8)
99
100 "OpenLDAP Administrator's Guide" (http://www.OpenLDAP.org/doc/admin/)
101
103 OpenLDAP Software is developed and maintained by The OpenLDAP Project
104 <http://www.openldap.org/>. OpenLDAP Software is derived from the Uni‐
105 versity of Michigan LDAP 3.3 Release.
106
107
108
109OpenLDAP 2.6.3 2022/07/14 SLAPINDEX(8C)