[Date Prev][Date Next] [Chronological] [Thread] [Top]

RE: (ITS#8337) olcDbChecksum not allowed in olcHdbConfig/olcBdbConfig



>From: Howard Chu [mailto:hyc@symas.com]=20
>Sent: Saturday, 12 December 2015 17:15
>To: Penza Kenneth at MITA; openldap-its@OpenLDAP.org
>Subject: Re: (ITS#8337) olcDbChecksum not allowed in olcHdbConfig/olcBdbCo=
nfig
>
>kenneth.penza@gov.mt wrote:
>> Full_Name: Kenneth Penza
>> Version: 2.4.43
>> OS: CentOS 7.1
>> URL: ftp://ftp.openldap.org/incoming/
>> Submission from: (NULL) (46.11.36.84)
>>
>>
>> olcDbChecksum is not accepted for BDB and HDB backends (whilst its=20
>> documented in the manual pages). Below please find files and steps to re=
produce.
>
>Thanks for the report, fixed now in git master.
>>
>> File attached:
>>
>> configbdb.ldif - ldif file to create config database with BDB backend=20
>> and checksum enabled. Uploaded in=20
>> ftp://ftp.openldap.org/incoming/kenneth-penza-151212-configbdb.ldif
>>
>> confighdb.ldif - ldif file to create config database with HDB backend=20
>> and checksum enabled. Uploaded in=20
>> ftp://ftp.openldap.org/incoming/kenneth-penza-151212-confighdb.ldif
>>
>> Test case:
>>
>> mkdir -p /tmp/dummyconfig/slapd.d.{b,h}db cd /tmp/dummyconfig
>>
>> slapadd -v -F slapd.d.bdb -n 0 -l configbdb.ldif slapadd -v -F=20
>> slapd.d.hdb -n 0 -l confighdb.ldif
>>
>>
>> For BDB it reports:
>>
>> 566c3f04 Entry (olcDatabase=3D{2}bdb,cn=3Dconfig), attribute=20
>> 'olcDbChecksum' not allowed
>> slapadd: dn=3D"olcDatabase=3D{2}bdb,cn=3Dconfig" (line=3D1070): (65) att=
ribute=20
>> 'olcDbChecksum' not allowed
>>
>> For HDB it reports:
>>
>> 566c41e2 Entry (olcDatabase=3D{2}hdb,cn=3Dconfig), attribute=20
>> 'olcDbChecksum' not allowed
>> slapadd: dn=3D"olcDatabase=3D{2}hdb,cn=3Dconfig" (line=3D1070): (65) att=
ribute=20
>> 'olcDbChecksum' not allowed
>>
>> Kenneth
>>
>>
>
>
>--=20
>   -- Howard Chu
>   CTO, Symas Corp.           http://www.symas.com
>   Director, Highland Sun     http://highlandsun.com/hyc/
>   Chief Architect, OpenLDAP  http://www.openldap.org/project/

I have pulled the sources that had the fix from the git repository and reco=
mpiled openldap. Following the patch, config creation worked fine.

To verify that it is working as expected, I tested with the olcDbChecksum s=
et to true/false and verified the checksum flag of the database created as =
per below output.

For both BDB/HDB backends, olcDbChecksum set to true, removed all files und=
er /var/lib/ldap/*  and started server to re-create database.

[root@host01 ldap]# db_dump /var/lib/ldap/dn2id.bdb=20
VERSION=3D3
format=3Dbytevalue
type=3Dbtree
chksum=3D1
duplicates=3D1
dupsort=3D1
db_pagesize=3D4096
HEADER=3DEND
DATA=3DEND
[root@host01 ldap]#=20

For both BDB/HDB backends, olcDbChecksum set to false, removed all files un=
der /var/lib/ldap/*  and started server to re-create database.

[root@host01 ldap]# db_dump /var/lib/ldap/dn2id.bdb=20
VERSION=3D3
format=3Dbytevalue
type=3Dbtree
duplicates=3D1
dupsort=3D1
db_pagesize=3D4096
HEADER=3DEND
DATA=3DEND
[root@host01 ldap]#=20

>From the output above, it is working as expected. Thanks for your prompt su=
pport and patch.

Regards
Kenneth