]> git.sur5r.net Git - openldap/blob - doc/guide/admin/appendix-common-errors.sdf
To tidy and filter out N/A stuff for 2.4.
[openldap] / doc / guide / admin / appendix-common-errors.sdf
1 # $OpenLDAP$
2 # Copyright 2007 The OpenLDAP Foundation, All Rights Reserved.
3 # COPYING RESTRICTIONS APPLY, see COPYRIGHT.
4
5 H1: Common errors encountered when using OpenLDAP Software
6
7 The following sections attempt to summarize the most common causes of LDAP errors 
8 when using OpenLDAP
9
10 H2: Common causes of LDAP errors
11
12 H3: ldap_*: Can't contact LDAP server
13
14 The {[B:Can't contact LDAP server}} error is usually returned when the LDAP 
15 server cannot be contacted. This may occur for many reasons:
16
17 * the LDAP server is not running; this can be checked by running, for example,
18
19 >      telnet <host> <port>
20
21 replacing {{<host>}} and {{<port>}} with the hostname and the port the server 
22 is supposed to listen on.
23 * the client has not been instructed to contact a running server; with OpenLDAP 
24 command-line tools this is accomplished by providing the -H switch, whose 
25 argument is a valid LDAP url corresponding to the interface the server is supposed to be listening on.
26
27 H3: ldap_*: No such object
28
29 The {{B:no such object}} error is generally returned when the target DN of the 
30 operation cannot be located. This section details reasons common to all 
31 operations. You should also look for answers specific to the operation 
32 (as indicated in the error message).
33
34 The most common reason for this error is non-existance of the named object. First, 
35 check for typos.
36
37 Also note that, by default, a new directory server holds no objects 
38 (except for a few system entries). So, if you are setting up a new directory 
39 server and get this message, it may simply be that you have yet to add the 
40 object you are trying to locate.
41
42 The error commonly occurs because a DN was not specified and a default was not properly configured.
43
44 If you have a suffix specified in slapd.conf eg.
45
46 >      suffix "dc=example,dc=com"
47
48 You should use
49
50   ldapsearch -b 'dc=example,dc=com' '(cn=jane*)'
51
52 to tell it where to start the search.
53
54 The -b should be specified for all LDAP commands unless you have an ldap.conf(5) default configured.
55
56 See Also: ldapsearch(1), ldapmodify(1), and (Xref) How do I specify default base DN for clients?
57 Also, slapadd(8) and its ancillary programs are very strict about the syntax of the LDIF file. Some liberties in the LDIF file may result in an apparently successful creation of the database, but accessing some parts of it may be difficult.
58
59 One known common error in database creation is putting a blank line before the first entry in the LDIF file. There must be no leading blank lines in the LDIF file.
60
61 It is generally recommended that ldapadd(1) be used instead of slapadd(8) when adding new entries your directory. slapadd(8) should be used to bulk load entries known to be valid.
62 Another cause of this message is a referral entry to an unpopulated directory. Either remove the referral, or add a single record with the referral base DN to the empty directory.
63 This error may also occur when slapd is unable to access the contents of its database because of file permission problems. For instance, on a RedHat Linux system, slapd runs as user 'ldap'. When slapadd is run as root to create a database from scratch, the contents of /var/lib/ldap are created with user and group root and with permission 600, making the contents unaccessable to the slapd server.
64 [Append to This Answer]
65 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: Can't chase referral
66 This is caused by the line
67
68 referral        ldap://root.openldap.org
69
70 in slapd.conf, It was provided as an example for how to use referrals in the original file. however if your machine is not permanently connected to the Internet, it will fail to find the server, and hence produce an error message.
71
72 To resolve, just place a # infront of line and restart slapd or point it to an available ldap server.
73 See also: ldapadd(1) ldapmodify(1) slapd.conf(5)
74 [Append to This Answer]
75 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: server is unwilling to perform
76 The OpenLDAP server will return an unwilling to perform error if the backend holding the target entry does not support the given operation.
77 The password backend is only willing to perform searches. It will return an unwilling to perform error for all other operations.
78 The shell backend is configurable and may support a limited subset of operations.
79 Check for other errors indicating a shortage of resources required by the directory server. i.e. you may have a full disk etc
80 [Append to This Answer]
81 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: Insufficient access
82 This error occurs when server denies the operation due to insufficent access. This is usually caused by binding to a DN with insufficient priviledges (or binding anonymously) to perform the operation. You can bind as the rootdn/rootpw specified in slapd.conf(5) to gain full access. Otherwise, you must bind to an entry which has been granted the appropriate rights through access controls.
83 See also: ldapadd(1) ldapdelete(1) ldapmodify(1) ldapmodrdn(1) ldapsearch(1) slapd.conf(5)
84 (Xref) ldap_bind: Insufficient access (Xref) Access Control
85 [Append to This Answer]
86 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: Invalid DN syntax
87 The target (or other) DN of the operation is invalid. This implies that either the string representation of the DN is not in the required form, one of the types in the attribute value assertions is not defined, or one of the values in the attribute value assertions does not conform to the appropriate syntax.
88 [Append to This Answer]
89 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: Referral hop limit exceeded
90 This error generally occurs when the client chases a referral which refers itself back to a server it already contacted. The server responds as it did before and the client loops. This loop is detected when the hop limit is exceeded.
91
92 This is most often caused through misconfiguration of the server's default referral. The default referral should not be itself:
93
94 That is, on ldap://myldap/ the default referral should not be ldap://myldap/ (or any hostname/ip which is equivalent to myldap).
95 [Append to This Answer]
96 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: operations error
97 In some versions of slapd(8), operationsError was returned instead of other. See also: (Xref) ldap_*: other error.
98 [Append to This Answer]
99 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: other error
100 The other result code indicates an internal error has occurred. While the additional information provided with the result code might provide some hint as to the problem, often one will need to consult the server's log files.
101 [Append to This Answer]
102 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add/modify: Invalid syntax
103 This error is reported when a value of an attribute does not conform to syntax restrictions. Additional information is commonly provided stating which value of which attribute was found to be invalid. Double check this value and other values (the server will only report the first error it finds).
104
105 Common causes include:
106
107  extraneous white space (especially trailing white space)
108  improperly encoded characters (LDAPv3 uses UTF-8 encoded Unicode)
109  empty values (few syntaxes allow empty values)
110
111
112 For certain syntax, like OBJECT IDENTIFER (OID), this error can indicate that the OID descriptor (a "short name") provided is unrecongized. For instance, this error is returned if the objectClass value provided is unrecongized.
113 [Append to This Answer]
114 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add/modify: Object class violation
115 This error is returned with the entry to be added or the entry as modified violates the object class schema rules. Normally additional information is returned the error detailing the violation. Some of these are detailed below.
116
117 Violations related to the entry's attributes:
118
119     Attribute not allowed
120         A provided attribute is not allowed by the entry's object class(es). 
121     Missing required attribute
122         An attribute required by the entry's object class(es) was not provided. 
123
124 Violations related to the entry's class(es):
125
126     Entry has no objectClass attribute
127         The entry did not state which object classes it belonged to. 
128     Unrecognized objectClass
129         One (or more) of the listed objectClass values is not recognized. 
130     No structural object class provided
131         None of the listed objectClass values is structural. 
132     Invalid structural object class chain
133         Two or more structural objectClass values are not in same structural object class chain. See also (Xref) ldap add: invalid structural object class chain. 
134     Structural object class modification
135         Modify operation attempts to change the structural class of the entry. See also (Xref) ldap_modify: cannot modify object class. 
136     Instanstantiation of abstract objectClass.
137         An abstract class is not subordinate to any listed structural or auxiliary class. 
138     Invalid structural object class
139         Other structural object class problem. 
140     No structuralObjectClass operational attribute
141         This is commonly returned when a shadow server is provided an entry which does not contain the structuralObjectClass operational attribute. 
142
143
144 Note that the above error messages as well as the above answer assumes basic knowledge of LDAP/X.500 schema.
145 [Append to This Answer]
146 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add: No such object
147 The "ldap_add: No such object" error is commonly returned if parent of the entry being added does not exist. Add the parent entry first...
148
149 For example, if you are adding "cn=bob,dc=domain,dc=com" and you get:
150
151   ldap_add: No such object
152
153 The entry "dc=domain,dc=com" likely doesn't exist. You can use ldapsearch to see if does exist:
154
155   ldapsearch -b 'dc=domain,dc=com' -s base '(objectclass=*)'
156
157 If it doesn't, add it. See the Quick Start Guide (http://www.openldap.org/doc/admin/quickstart.html) for assistance.
158
159 Note: if the entry being added is the same as database suffix, it's parent isn't required. Ie: if your suffix is "dc=domain,dc=com", "dc=com" doesn't need to exist to add "dc=domain,dc=com".
160 This error will also occur if you try to add any entry that the server is not configured to hold.
161
162 For example, if your database suffix is "dc=domain,dc=com" and you attempt to add "dc=domain2,dc=com", "dc=com", "dc=domain,dc=org", "o=domain,c=us", or an other DN in the "dc=domain,dc=com" subtree, the server will return a "No such object" (or referral) error.
163
164 slapd(8) will generally return "no global superior knowledge" as additional information indicating its return noSuchObject instead of a referral as the server is not configured with knowledge of a global superior server.
165 See also: ldapadd(1) ldapmodify(1) (Xref) ldap_add/delete/modify/rename: no global superior knowledge
166 [Append to This Answer]
167 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap add: invalid structural object class chain
168 This particular error refers to the rule about STRUCTURAL objectclasses, which states that an object is of one STRUCTURAL class, the structural class of the object. The object is said to belong to this class, zero or more auxiliaries classes, and their superclasses. While all of these classes are commonly listed in the objectClass attribute of the entry, one of these classes is the structural object class of the entry. Thus, it is OK for an objectClass attribute to contain inetOrgPerson, organizationalPerson, and person because they inherit one from another to form a single superclass chain. That is, inetOrgPerson SUPs organizationPerson SUPs person. On the other hand, it is invalid for both inetOrgPerson and account to be listed in objectClass as inetOrgPerson and account are not part of the same superclass chain (unless some other class is also listed with is a subclass of both).
169
170 To resolve this problem, one must determine which class will better serve structural object class for the entry, adding this class to the objectClass attribute (if not already present), and remove any other structural class from the entry's objectClass attribute which is not a superclass of the structural object class.
171
172 Which object class is better depends on the particulars of the situation. One generally should consult the documentation for the applications one is using for help in making the determination.
173 [Append to This Answer]
174 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add: no structuralObjectClass operational attribute
175 ldapadd(1) may error:
176
177   adding new entry "uid=XXX,ou=People,o=campus,c=ru"
178   ldap_add: Internal (implementation specific) error (80)
179      additional info: no structuralObjectClass operational attribute
180
181 when slapd(8) cannot determine, based upon the contents of the objectClass attribute, what the structural class of the object should be.
182
183 While this normally should produce an object class violation error, some versions of slapd(8) contain a minor bug which cause the object class error not to be properly detected. In these versions, slapd(8) instead catches its failure to populate the structuralObjectClass operational attribute (hence the internal error).
184 Kurt@OpenLDAP.org
185 See also: (Xref) ldap add: invalid structural object class chain
186 Kurt@OpenLDAP.org
187 [Append to This Answer]
188 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add/modify/rename: Naming violation
189 OpenLDAP's slapd checks for naming attributes and distinguished values consistency, according to RFC 4512.
190
191 Naming attributes are those attributeTypes that appear in an entry's RDN; distinguished values are the values of the naming attributes that appear in an entry's RDN, e.g, in
192
193     cn=Someone+mail=someone@example.com,dc=example,dc=com
194
195 the naming attributes are cn and mail, and the distinguished values are Someone and someone@example.com.
196
197 OpenLDAP's slapd checks for consistency when:
198
199     * adding an entry
200     * modifying an entry, if the values of the naming attributes are changed
201     * renaming an entry, if the RDN of the entry changes
202
203 Possible causes of error are:
204
205     * the naming attributes are not present in the entry; for example:
206
207           dn: dc=example,dc=com
208           objectClass: organization
209           o: Example
210           # note: "dc: example" is missing
211
212     * the naming attributes are present in the entry, but in the attributeType definition they are marked as:
213           o collective
214           o operational
215           o obsolete
216     * the naming attributes are present in the entry, but the distinguished values are not; for example:
217
218           dn: dc=example,dc=com
219           objectClass: domain
220           dc: foobar
221           # note: "dc" is present, but the value is not "example"
222
223     * the naming attributes are present in the entry, with the distinguished values, but the naming attributes:
224           o do not have an equality field, so equality cannot be asserted
225           o the matching rule is not supported (yet)
226           o the matching rule is not appropriate
227     * the given distinguished values do not comply with their syntax
228     * other errors occurred during the validation/normalization/match process; this is a catchall: look at previous logs for details in case none of the above apply to your case.
229
230 In any case, make sure that the attributeType definition for the naming attributes contains an appropriate EQUALITY field; or that of the superior, if they are defined based on a superior attributeType (look at the SUP field). See RFC 4512 for details.
231 ando@sys-net.it, Kurt@OpenLDAP.org
232 [Append to This Answer]
233 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_add/delete/modify/rename: no global superior knowledge
234 If the target entry name places is not within any of the databases the server is configured to hold and the server has no knowledge of a global superior, the server will indicate it is unwilling to perform the operation and provide the text "no global superior knowledge" as additional text.
235
236 Likely the entry name is incorrect, or the server is not properly configured to hold the named entry, or, in distributed directory environments, a default referral was not configured.
237 Kurt@OpenLDAP.org
238 [Append to This Answer]
239 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_bind: Insufficient access
240 Current versions of slapd(8) requires that clients have authentication permission to attribute types used for authentication purposes before accessing them to perform the bind operation. As all bind operations are done anonymously (regardless of previous bind succuss), the auth access must be granted to anonymous.
241
242 In the example ACL below grants the following access:
243
244     * to anonymous users:
245           o permission to authenticate using values of userPassword
246     * to authenticated users:
247           o permission to update (but not read) their userPassword
248           o permission to read any object excepting values of userPassword 
249
250 All other access is denied.
251
252   access to attr=userpassword
253     by self =w
254     by anonymous auth
255
256   access *
257     by self write
258     by users read
259
260
261 Note that latest versions of slapd(8) will report invalid credentials in cases where the client has insufficient access to complete the operation. This is avoid inappropriate disclosure of the validity of the user's name.
262 See also: ldapadd(1) ldapdelete(1) ldapmodify(1) ldapmodrdn(1) ldapsearch(1) slapd.conf(5) (Xref) Access Control
263 [Append to This Answer]
264 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_bind: Invalid credentials
265 The error usually occurs when the credentials (password) provided does not match the userPassword held in entry you are binding to.
266
267 The error can also occur when the bind DN specified is not known to the server.
268
269 Check both!
270 In addition to the cases mentioned above you should check if the server denied access to userPassword on selected parts of the directory. In fact, slapd always returns "Invalid credentials" in case of failed bind, regardless of the failure reason, since other return codes could reveal the validity of the user's name.
271
272 To debug access rules defined in slapd.conf, add "ACL" to log level.
273 See also: ldapadd(1) ldapdelete(1) ldapmodify(1) ldapmodrdn(1) ldapsearch(1) slapd.conf(5) (Xref) ldap_bind: No such object
274 [Append to This Answer]
275 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_bind: No such object
276 This answer is specific to OpenLDAP 1.2 and earlier releases. In later relases, ldap_bind returns (Xref) ldap_bind: Invalid credentials instead.
277 'No such object' is only returned by ldap_bind operation in a few special cases. Normally, the server returns (Xref) ldap_bind: Invalid credentials when the entry associated with the bind DN cannot be located.
278 This error occurs when binding using the rootdn and the asserted value doesn't match configured password value. Rootpw values must be conform to RFC 2307 format defined for userPassword.
279 See also: ldapadd(1) ldapdelete(1) ldapmodify(1) ldapmodrdn(1) ldapsearch(1) slapd.conf(5) (Xref) ldap_bind: Invalid credentials
280 [Append to This Answer]
281 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_bind: Protocol error
282 There error is generally occurs when the LDAP version requested by the client is not supported by the server.
283
284 The OpenLDAP Software 1.x server only accepts version 2 LDAP Bind requests. Note that 1.x server expects U-Mich LDAP, an LDAPv2 variant, to be used. This variant is sometimes referred to as LDAPv2+.
285
286 The OpenLDAP Software 2.x server, by default, only accepts version 3 LDAP Bind requests but can be configured to accept a version 2 LDAP Bind request. Note that the 2.x server expects LDAPv3 [RFC4510] to be used when the client requests version 3 and expects a limited LDAPv3 variant (basically, LDAPv3 syntax and semantics in an LDAPv2 PDUs) to be used when version 2 is expected. This variant is also sometimes referred to as LDAPv2+, but differs from the U-Mich LDAP variant in a number of ways.
287
288 Use of LDAPv3!
289 See also: (Xref) How to configure slapd(8) with LDAPv2 support (for legacy clients)?.
290 [Append to This Answer]
291 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_modify: cannot modify object class
292 This message is commonly returned when attempting to modify the objectClass attribute in a manner inconsistent with the LDAP/X.500 information model. In particular, it commonly occurs when one tries to change the structure of the object from one class to another, for instance, trying to change an 'apple' into a 'pear' or a 'fruit' into a 'pear'. Such changes are disallowed by the slapd(8) in accordance with LDAP and X.500 restrictions.
293
294 To overcome this restriction in 2.3 (and prior releases), one must re-create the object with the desired new structural object class (e.g., delete old object then add new object). In 2.4, support for a new control will (hopefully) be introduced to allow the (authorized) user to request this (and various other model restrictions) be temporarily relaxed.
295 [Append to This Answer]
296 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: ...
297 If you intended to bind using a DN and password and get an error from ldap_sasl_interactive_bind_s, you likely forgot to provide a '-x' option to the command. By default, SASL authentication is used. '-x' is necessary to select "simple" authentication.
298 Kurt@OpenLDAP.org
299 [Append to This Answer]
300 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: No such Object
301 This indicates that LDAP SASL authentication function could not read the Root DSE.
302 The error will occur when the server doesn't provide a root DSE. This may be due to access controls.
303
304 Note, also, that LDAPv2 servers, such as those OpenLDAP 1.x's slapd(8), do not provide a root DSE. Use -P 2 when LDAPv2 is desired. LDAPv2 servers also do not support SASL binds, so you will need to use a "simple" bind instead.
305 Note: SASL bind is the default for all OpenLDAP tools. To force use of "simple" bind, use the "-x" option. Use of "simple" bind is not recommended unless one has adequate confidentiality protection in place (e.g. TLS/SSL, IPSEC).
306 [Append to This Answer]
307 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: No such attribute
308 This indicates that LDAP SASL authentication function could read the Root DSE but it contained no supportedSASLMechanism attribute.
309 The supportedSASLmechanism attribute lists mechanisms currently available. The list may be empty because none of the supported mechanisms are currently available. For example, EXTERNAL is listed only if the client has established its identity by authenticating at a lower level (e.g. TLS).
310 Note: the attribute may not be visible due to access controls
311 Note: SASL bind is the default for all OpenLDAP tools, e.g. ldapsearch(1), ldapmodify(1). To force use of "simple" bind, use the "-x" option. Use of "simple" bind is not recommended unless one has adequate confidentiality protection in place (e.g. TLS/SSL, IPSEC).
312 [Append to This Answer]
313 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: Unknown authentication method
314 This indicates that none of the SASL authentication supported by the server are supported by the client, or that they are too weak or otherwise inappropriate for use by the client. Note that the default security options disallows the use of certain mechanisms such as ANONYMOUS and PLAIN (without TLS).
315 Note: SASL bind is the default for all OpenLDAP tools. To force use of "simple" bind, use the "-x" option. Use of "simple" bind is not recommended unless one has adequate confidentiality protection in place (e.g. TLS/SSL, IPSEC).
316 [Append to This Answer]
317 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: Local error (82)
318 Apparently not having forward and reverse DNS entries for the LDAP server can result in this error.
319
320 [Append to This Answer]
321 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_search: Partial results and referral received
322 This error is returned with the server responses to an LDAPv2 search query with both results (zero or more matched entried) and references (referrals to other servers).
323 See also: ldapsearch(1).
324 If the updatedn on the replica does not exist, a referral will be returned. It may do this as well if the ACL needs tweeking.
325 [Append to This Answer]
326 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_start_tls: Operations error
327 ldapsearch(1) and other tools will return
328
329   ldap_start_tls: Operations error (1)
330         additional info: TLS already started
331
332 when the user (though command line options and/or ldap.conf(5)) has requested TLS (SSL) be started twice. For instance, when specifying both "-H ldaps://server.do.main" and "-ZZ".
333 [Append to This Answer]
334 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ber_get_next on fd X failed errno=34 (Numerical result out of range)
335 This slapd error generally indicates that the client sent a message that exceeded an administrative limit. See sockbuf_max_incoming and sockbuf_max_incoming_auth configuration directives in slapd.conf(5).
336 [Append to This Answer]
337 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ber_get_next on fd X failed errno=11 (Resource temporarily unavailable)
338 This message is not indicative of abnormal behavior or error. It simply means that expected data is not yet available from the resource, in this context, a network socket. slapd(8) will process the data once it does becomes available.
339 [Append to This Answer]
340 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) daemon: socket() failed errno=97 (Address family not supported)
341 This message indicates that the operating system does not support one of the (protocol) address families which slapd(8) was configured to support. Most commonly, this occurs when slapd(8) was configured to support IPv6 yet the operating system kernel wasn't. In such cases, the message can be ignored.
342 [Append to This Answer]
343 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) GSSAPI: gss_acquire_cred: Miscellaneous failure; Permission denied;
344 This message means that slapd is not running as root and, thus, it cannot get its Kerberos 5 key from the keytab, usually file /etc/krb5.keytab.
345
346 A keytab file is used to store keys that are to be used by services or daemons that are started at boot time. It is very important that these secrets are kept beyond reach of intruders.
347
348 That's why the default keytab file is owned by root and protected from being read by others. Do not mess with these permissions, build a different keytab file for slapd instead.
349
350 To do this, start kadmin, and enter the following commands:
351
352     * addprinc -randkey ldap/ldap.example.com@EXAMPLE.COM
353     * ktadd -k /etc/openldap/ldap.keytab ldap/ldap.example.com@EXAMPLE.COM 
354
355 Then, on the shell, do:
356
357     * chown ldap.ldap /etc/openldap/ldap.keytab
358     * chmod 600 /etc/openldap/ldap.keytab 
359
360 Now you have to tell slapd (well, actually tell the gssapi library in Kerberos 5 that is invoked by Cyrus SASL) where to find the new keytab. You do this by setting the environment variable KRB5_KTNAME like this:
361
362 export KRB5_KTNAME="FILE:/etc/openldap/ldap.keytab"
363
364 Set that environment variable on the slapd start script (RedHat users might find /etc/sysconfig/ldap a perfect place).
365 jsanchez@openldap.org, hyc@openldap.org
366 This only works if you are using MIT kerberos. It doesn't work with Heimdal, for instance.
367 andreas@conectiva.com.br
368 In Heimdal there is a function gsskrb5_register_acceptor_identity() that sets the path of the keytab file you want to use. In Cyrus SASL 2 you can add
369
370     keytab: /path/to/file
371
372 to your application's SASL config file to use this feature. This only works with Heimdal.
373 hyc@openldap.org
374 [Append to This Answer]
375 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) access from unknown denied
376 This related to TCP wrappers. See hosts_access(5) for more information.
377 in the log file: "access from unknown denied" This related to TCP wrappers. See hosts_access(5) for more information.
378 for example: add the line "slapd: .hosts.you.want.to.allow" in /etc/hosts.allow to get rid of the error.
379 [Append to This Answer]
380 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_read: want=# error=Resource temporarily unavailable
381 This message occurs normally. It means that pending data is not yet available from the resource, a network socket. slapd(8) will process the data once it becomes available.
382 [Append to This Answer]
383 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) `make test' fails
384 Some times, `make test' fails at the very first test with an obscure message like
385
386     make test
387     make[1]: Entering directory `/ldap_files/openldap-2.2.13/tests'
388     make[2]: Entering directory `/ldap_files/openldap-2.2.13/tests'
389     Initiating LDAP tests for BDB...
390     Cleaning up test run directory leftover from previous run.
391     Running ./scripts/all...
392     >>>>> Executing all LDAP tests for bdb
393     >>>>> Starting test000-rootdse ...
394     running defines.sh
395     Starting slapd on TCP/IP port 9011...
396     Using ldapsearch to retrieve the root DSE...
397     Waiting 5 seconds for slapd to start...
398     ./scripts/test000-rootdse: line 40: 10607 Segmentation fault $SLAPD -f $CONF1 -h $URI1 -d $LVL $TIMING >$LOG1 2>&1
399     Waiting 5 seconds for slapd to start...
400     Waiting 5 seconds for slapd to start...
401     Waiting 5 seconds for slapd to start...
402     Waiting 5 seconds for slapd to start...
403     Waiting 5 seconds for slapd to start...
404     ./scripts/test000-rootdse: kill: (10607) - No such pid
405     ldap_bind: Can't contact LDAP server (-1)
406     >>>>> Test failed
407     >>>>> ./scripts/test000-rootdse failed (exit 1)
408     make[2]: *** [bdb-yes] Error 1
409     make[2]: Leaving directory `/ldap_files/openldap-2.2.13/tests'
410     make[1]: *** [test] Error 2
411     make[1]: Leaving directory `/ldap_files/openldap-2.2.13/tests'
412     make: *** [test] Error 2
413
414 or so. Usually, the five lines
415
416     Waiting 5 seconds for slapd to start...
417
418 indicate that slapd didn't start at all.
419
420 For OpenLDAP 2.2 and later, in tests/testrun/slapd.1.log there is a full log of what slapd wrote while trying to start. The log level can be increased by setting the environment variable SLAPD_DEBUG to the corresponding value; see loglevel in slapd.conf(5) for the meaning of log levels.
421
422 A typical reason for this behavior is a runtime link problem, i.e. slapd cannot find some dynamic libraries it was linked against. Try running ldd(1) on slapd (for those architectures that support runtime linking).
423
424 There might well be other reasons; the contents of the log file should help clarifying them.
425
426 Tests that fire up multiple instances of slapd typically log to tests/testrun/slapd.<n>.log, with a distinct <n> for each instance of slapd; list tests/testrun/ for possible values of <n>.
427 ando@sys-net.it
428 [Append to This Answer]
429 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_*: Internal (implementation specific) error (80) - additional info: entry index delete failed
430 This seems to be related with wrong ownership of the BDB's dir (/var/lib/ldap) and files.
431 chmod -r openldap:openldap /var/lib/ldap fixes it in Debian Etch.
432 I don't really know how the wrong permission went into place, but I suspect it has something to do with slapd's starting, no database existing (I had deleted it to get a new, fresh one), and slapd creating one before chroot.
433 After a bug report, some insightfull feedback, and some amount of testing, i found out that the 'wrong ownership of new files' problem is not with slapd but with slapadd. This happens when one initially populates the Directory.
434 Oh, and the right switch of chown is '-R', not '-r'.
435 My God! What a mess! The right command to correct this problem is: chown -R /var/lib/ldap
436 [Append to This Answer]
437 pedrorandrade@gmail.com
438 (Answer)        (Category) OpenLDAP Faq-O-Matic : (Category) OpenLDAP Software FAQ : (Category) Common Errors : (Answer) ldap_sasl_interactive_bind_s: Can't contact LDAP server (-1)
439 Using SASL, when a client contacts LDAP server, the slapd service dies immediately and client gets an error :
440 SASL/GSSAPI authentication started ldap_sasl_interactive_bind_s: Can't contact LDAP server (-1)
441 Then check the slapd service, it stoped.
442 This may come from incompatible of using different versions of BerkeleyDB for installing of SASL and installing of OpenLDAP. The problem arises in case of using multiple version of BerkeleyDB. Solution: - Check which version of BerkeleyDB when install Cyrus SASL. - Reinstall OpenLDAP with the version of BerkeleyDB above.
443 It was my case and that was the solution I did and it worked :) Hope this gives you some information.
444 -- Le Trung Kien 
445