4

I want to setup my postfix with ldap authentication. I follow this tutorial https://blog.tnyc.me/postfix-with-ldap

I need to setup a PostfixBookMailAccount but therefore i need to load that schema. I tried this one schema and adjusted the attributetype to attributetype:, same for objectclass (syntax change in newer ldap version)

Loading this schema looks good without an error.

root@openldap:~/postfix# ldapadd -Y EXTERNAL -H ldapi:/// -f /etc/ldap/schema/postfix-book.ldif 
SASL/EXTERNAL authentication started
SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth
SASL SSF: 0

But i can not choose a schema called PostfixBookMailAccount!

Any ideas?


Edit

Ok I found out that i have to convert the schema to a ldif first ... but doing this results in an error

root@openldap:/etc/ldap/schema# cat schema_conv.conf  
include /etc/ldap/schema/postfix-book.schema

root@openldap:/etc/ldap/schema# slaptest -f ./schema_conv.conf -F /tmp/ldif/
5d3d5e5c /etc/ldap/schema/postfix-book.schema: line 72 objectclass: AttributeType not found: "mail"

1 Answer 1

4

Ok I had to add some core schemas to be able to convert the postfix schema

include /etc/ldap/schema/core.schema
include /etc/ldap/schema/cosine.schema
include /etc/ldap/schema/inetorgperson.schema
include /etc/ldap/schema/nis.schema
include /tmp/ldif/ldap-mail-schema-master/postfix-book.schema

then slaptest did the job

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.