[Date Prev][Date Next]
Indexing, use of slapindex
- To: email@example.com
- Subject: Indexing, use of slapindex
- From: anax <firstname.lastname@example.org>
- Date: Fri, 19 Aug 2011 11:27:03 +0200
- User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:220.127.116.11) Gecko/20110428 Fedora/3.1.10-1.fc13 Thunderbird/3.1.10
One master server, two backup servers (syncrepl).
All authentication and mailing is managed by ldap.
1. About indexing:
When i check the slapd-log, i see many
<= bdb_equality_candidates: (uidNumber) not indexed
<= bdb_equality_candidates: (gidNumber) not indexed
In the discussion about slapd tuning
http://www.openldap.org/doc/admin24/tuning.html#Indexes, however, i read
that if each entry in a certain set of ldap-entries has got the
candidate-attribute, it is not worth while to index the attribute,
because slapd needs to read each entry in any case in order to find the
requested one. this is the case for uidNumber as well as gidNumber,
because both are compulsory attributes for objectClass posixAccount.
My first question:
is it therefore correct to disregard the above indexing requests of slapd?
2. About slapindex:
When it comes to use slapindex, the docu is not clear about how to do
that. Some places say, that you need to stop slapd entirely, some places
say that it is sufficient to put slapd in read-only mode for the
corresponding background database, which in this case would be
this file contains both the olcReadOnly and the olcDbIndex attributes.
So i could just add the following two lines in the above file:
olcDbIndex: uidNumber eq
olcDbIndex: gidNumber eq
set the olcReadOnly attribute to TRUE, and restart slapd, and everything
would be done automatically?
Or would i need to invoke slapindex additionally with the following command
And if i had to start slapindex additionally, would slapindex tell me,
that the database is in read-only mode, so no changes are possible, not
even index changes?
And, if i had to start slapindex additionally, i would do it as root.
the files generated by slapindex would they be owned by root
(inaccessible by slapd) or by the slapd user?
Would the new indexes be propagated to the backup servers by syncrepl
automatically? If not, what would i have to change on the backup servers?
Thank you for your attention