Merge lp:~ahasenack/serverguide/samba-indexes-1603540 into lp:serverguide/trunk
Status: | Merged |
---|---|
Approved by: | Doug Smythies |
Approved revision: | 322 |
Merged at revision: | 320 |
Proposed branch: | lp:~ahasenack/serverguide/samba-indexes-1603540 |
Merge into: | lp:serverguide/trunk |
Diff against target: |
42 lines (+9/-9) 1 file modified
serverguide/C/network-auth.xml (+9/-9) |
To merge this branch: | bzr merge lp:~ahasenack/serverguide/samba-indexes-1603540 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Doug Smythies | Approve | ||
Review via email:
|
Commit message
Fix proposed samba indexes to avoid duplication errors.
Description of the change
Fix proposed samba indexes to avoid duplication errors.
If you follow the step "Samba indices", and after you change the backend to mdb (that needs to be fixed all over the place and I will open a separate bug about that), you will get duplicate index errors.
That's because out of the box the package already gives you a few:
olcDbIndex: objectClass eq
olcDbIndex: cn,uid eq
olcDbIndex: uidNumber,gidNumber eq
olcDbIndex: member,memberUid eq
We should only add the indexes we need, but that's a bit complicated because you can't modify an existing "cn,uid eq" to "cn,uid eq,sub" (i.e., add "sub") without removing the index first.
An ldapmodify command to do that can be easily constructed, but I think that could get brittle with time because it would depend on the existing indexes the package gives you: if the maintainer decided to change that set, the instructions in the guide would start failing again.
Therefore I propose here to do a bulk index replacement via a "changetype: modify" followed by "replace: olcDbIndex". If this were done on a populated DIT, that would be a very expensive operation, because everything would be reindexed (I'm not sure if openldap knows that an index is being replaced by itself), but this guide assumes a fresh install of slapd, so I think we are good. I took care to merge the existing indexes you get after package installation with the ones we need for samba.
Other changes I did:
- I removed the "pres" index as the openldap admin guide basically says it's seldom useful (http://
- I added "eq" to the default index type, I think it's the most basic and used one
- grouped indexes of the same type in the same line to make this excerpt a bit shorter
O.K. thanks.
(in general, I'll have to take your word for it on the actual content changes, as I do not know.)