Samba LDAP new version error [AttributeType not found: “displayName]?

When I was updating to a new openldap server version, I got:

samba olcObjectClasses: AttributeType not found: "displayName"

I first tried recompiling the ldif’s with a new samba.schema (you can find samba.schema in here), that made no difference.

Solution is to move the files in /etc/openldap/slapd.d/cn=config/cn=schema . Change the numbering so that samba is after {core,corba,cosine,inetperson}.