ldbdel error

Bob Miller bob at computerisms.ca
Fri Aug 19 17:30:20 MDT 2011

Hi Matthieu,

> > So it would seem there is no deleting your mistakes and re-adding
> > correct entries as one might do in openldap, instead use ldbmodify to
> > correct mistakes.  Thank you for providing information that led me stop
> > imposing my presumptions on the software ;)
> The thing is that the schema is replicated between different DCs, once 
> it has been replicated you can create an object on DC B with the 
> attribute foo and in the same time remove the object definition for 
> attribute foo (on DC A) then when DC B will try to replicate the change 
> object A won't understand on which attribute.
> That's mostly why it's not authorized to remove an attribute.

That seems like a wise precaution to take...

> >
> > ERR: (Invalid attribute syntax) "LDAP error 21
> > LDAP_INVALID_ATTRIBUTE_SYNTAX -<0000200B: Invalid attribute syntax -
> > objectclass_attrs: attribute 'mayContain' on entry
> > 'CN=qmailUser,CN=Schema,CN=Configuration,dc=computerisms,dc=ca' contains
> > at least one invalid value!>  <>" on DN
> > CN=qmailUser,CN=Schema,CN=Configuration,dc=computerisms,dc=ca
> Maybe you can post the LDIF transofrmed ?

Yes, I will paste it below.  There is an example of the failing ldif and
a working one here:
> > http://computerisms.ca/ldif.txt
> >

# cat qmail.schema.ng - this is an excerpt 
## failed first time
attributetype ( NAME 'mailHost'
       DESC 'On which qmail server the messagestore of this user is
       EQUALITY caseIgnoreIA5Match
       SUBSTR caseIgnoreIA5SubstringsMatch
## succeeded first time
#attributetype ( NAME 'mailMessageStore'
#        DESC 'Path to the maildir/mbox on the mail system'
#        EQUALITY caseExactIA5Match
#        SUBSTR caseIgnoreIA5SubstringsMatch
#        SYNTAX{256} SINGLE-VALUE )

# /usr/local/samba/bin/oLschema2ldif -b
cn=schema,cn=Configuration,DC=computerisms,DC=ca -I qmail.schema.ng
-O /root/mailHost.ldif

# cat mailHost.ldif 
dn: CN=mailHost,CN=Schema,CN=Configuration,DC=computerisms,DC=ca
objectClass: top
objectClass: attributeSchema
schemaIdGuid:: fC7HPIx8Uq+aUMRP7QK03Q==
cn: mailHost
name: mailHost
lDAPDisplayName: mailHost
description: On which qmail server the messagestore of this user is
oMSyntax: 22
isSingleValued: TRUE

Bob Miller
bob at computerisms.ca
Network, Internet, Server,
and Open Source Solutions

More information about the samba-technical mailing list