]> git.sur5r.net Git - openldap/blob - doc/man/man5/slapd-mdb.5
bump mdb maxsize up to 32M to pass test060
[openldap] / doc / man / man5 / slapd-mdb.5
1 .TH SLAPD-MDB 5 "RELEASEDATE" "OpenLDAP LDVERSION"
2 .\" Copyright 2011 The OpenLDAP Foundation All Rights Reserved.
3 .\" Copying restrictions apply.  See COPYRIGHT/LICENSE.
4 .\" $OpenLDAP$
5 .SH NAME
6 slapd\-mdb \- Memory-Mapped DB backend to slapd
7 .SH SYNOPSIS
8 .B ETCDIR/slapd.conf
9 .SH DESCRIPTION
10 The \fBmdb\fP backend to
11 .BR slapd (8)
12 uses OpenLDAP's own Memory-Mapped DB (MDB) library to store data.
13 It relies completely on the underlying operating system for memory
14 management and does no caching of its own.
15 .LP
16 The \fBmdb\fP backend is similar to the \fBhdb\fP backend in that
17 it uses a hierarchical database layout which
18 supports subtree renames. It is both more space-efficient and more
19 execution-efficient than the \fBbdb\fP backend, while being overall
20 much simpler to manage.
21 .SH CONFIGURATION
22 These
23 .B slapd.conf
24 options apply to the \fBmdb\fP backend database.
25 That is, they must follow a "database mdb" line and
26 come before any subsequent "backend" or "database" lines.
27 Other database options are described in the
28 .BR slapd.conf (5)
29 manual page.
30 .TP
31 .BI checkpoint \ <kbyte>\ <min>
32 Specify the frequency for flushing the database disk buffers.
33 This setting is only needed if the \fBdbnosync\fP option is used.
34 Note: this feature is not yet implemented.
35 The checkpoint will occur if either \fI<kbyte>\fP data has been written or
36 \fI<min>\fP minutes have passed since the last checkpoint.
37 Both arguments default to zero, in which case they are ignored. When
38 the \fI<min>\fP argument is non-zero, an internal task will run every 
39 \fI<min>\fP minutes to perform the checkpoint.
40 .TP
41 .B dbnosync
42 Specify that on-disk database contents should not be immediately
43 synchronized with in memory changes.
44 Enabling this option may improve performance at the expense of data
45 security. By default, a full data flush/sync is performed when each
46 transaction is committed.
47 .TP
48 .BI directory \ <directory>
49 Specify the directory where the MDB files containing this database and
50 associated indexes live.
51 A separate directory must be specified for each database.
52 The default is
53 .BR LOCALSTATEDIR/openldap\-data .
54 .TP
55 \fBindex \fR{\fI<attrlist>\fR|\fBdefault\fR} [\fBpres\fR,\fBeq\fR,\fBapprox\fR,\fBsub\fR,\fI<special>\fR]
56 Specify the indexes to maintain for the given attribute (or
57 list of attributes).
58 Some attributes only support a subset of indexes.
59 If only an \fI<attr>\fP is given, the indices specified for \fBdefault\fR
60 are maintained.
61 Note that setting a default does not imply that all attributes will be
62 indexed. Also, for best performance, an
63 .B eq
64 index should always be configured for the
65 .B objectClass
66 attribute.
67
68 A number of special index parameters may be specified.
69 The index type
70 .B sub
71 can be decomposed into
72 .BR subinitial ,
73 .BR subany ,\ and
74 .B subfinal
75 indices.
76 The special type
77 .B nolang
78 may be specified to disallow use of this index by language subtypes.
79 The special type
80 .B nosubtypes
81 may be specified to disallow use of this index by named subtypes.
82 Note: changing \fBindex\fP settings in 
83 .BR slapd.conf (5)
84 requires rebuilding indices, see
85 .BR slapindex (8);
86 changing \fBindex\fP settings
87 dynamically by LDAPModifying "cn=config" automatically causes rebuilding
88 of the indices online in a background task.
89 .TP
90 .BI maxsize \ <bytes>
91 Specify the maximum size of the database in bytes. A memory map of this
92 size is allocated at startup time and the database will not be allowed
93 to grow beyond this size. The default is 10485760 bytes. This setting
94 may be changed upward if the configured limit needs to be increased.
95
96 Note: It is important to set this to as large a value as possible,
97 (relative to anticipated growth of the actual data over time) since
98 growing the size later may not be practical when the system is under
99 heavy load.
100 .TP
101 .BI mode \ <integer>
102 Specify the file protection mode that newly created database 
103 files should have.
104 The default is 0600.
105 .TP
106 .BI searchstack \ <depth>
107 Specify the depth of the stack used for search filter evaluation.
108 Search filters are evaluated on a stack to accommodate nested AND / OR
109 clauses. An individual stack is assigned to each server thread.
110 The depth of the stack determines how complex a filter can be
111 evaluated without requiring any additional memory allocation. Filters that
112 are nested deeper than the search stack depth will cause a separate
113 stack to be allocated for that particular search operation. These
114 allocations can have a major negative impact on server performance,
115 but specifying too much stack will also consume a great deal of memory.
116 Each search stack uses 512K bytes per level. The default stack depth
117 is 16, thus 8MB per thread is used.
118 .SH ACCESS CONTROL
119 The 
120 .B mdb
121 backend honors access control semantics as indicated in
122 .BR slapd.access (5).
123 .SH FILES
124 .TP
125 .B ETCDIR/slapd.conf
126 default 
127 .B slapd 
128 configuration file
129 .SH SEE ALSO
130 .BR slapd.conf (5),
131 .BR slapd\-config (5),
132 .BR slapd (8),
133 .BR slapadd (8),
134 .BR slapcat (8),
135 .BR slapindex (8),
136 OpenLDAP MDB documentation.
137 .SH ACKNOWLEDGEMENTS
138 .so ../Project
139 Written by Howard Chu.