Skip to content

Instantly share code, notes, and snippets.

@christopherwood
Created August 31, 2017 14:18
Show Gist options
  • Save christopherwood/2cf46f5a3384f9edc89e7eabbefc465e to your computer and use it in GitHub Desktop.
Save christopherwood/2cf46f5a3384f9edc89e7eabbefc465e to your computer and use it in GitHub Desktop.
ldif that led to the segfault
dn: cn=config
objectClass: olcGlobal
cn: config
olcArgsFile: /var/run/slapd/slapd.args
olcPidFile: /var/run/slapd/slapd.pid
dn: cn=module,cn=config
objectClass: olcModuleList
cn: module
olcModulepath: /opt/openldap/libexec/openldap
olcModuleload: accesslog.la
olcModuleload: syncprov.la
dn: cn=schema,cn=config
objectClass: olcSchemaConfig
cn: schema
include: file:///opt/openldap/etc/openldap/schema/core.ldif
include: file:///opt/openldap/etc/openldap/schema/cosine.ldif
include: file:///opt/openldap/etc/openldap/schema/nis.ldif
dn: olcDatabase={1}mdb,cn=config
objectClass: olcDatabaseConfig
objectClass: olcMdbConfig
olcDatabase: {1}mdb
olcDbDirectory: /var/lib/ldap/cn=accesslog
olcSuffix: cn=accesslog
olcRootDN: cn=accesslog
olcDbIndex: objectClass eq
olcDbIndex: reqEnd eq
olcDbIndex: reqStart eq
olcDbIndex: reqResult eq
dn: olcOverlay={0}syncprov,olcDatabase={1}mdb,cn=config
objectClass: olcConfig
objectClass: olcOverlayConfig
objectClass: olcSyncProvConfig
olcSpNoPresent: TRUE
olcSpReloadHint: TRUE
dn: olcDatabase={2}mdb,cn=config
olcRootDN: cn=admin,dc=poc
olcRootPW: {CRYPT}$6$q9IIPzVtSmZqy$vcbd/.EmT4r83lH3rTroEGWIQala3rwMLADRXeIAqIaVw8Rfz3r43QNEbRzXfhgoHY/THw5CLI0kjCtGkW9DK.
olcSuffix: dc=poc
olcMirrorMode: TRUE
objectClass: olcDatabaseConfig
objectClass: olcMdbConfig
olcDatabase: {2}mdb
olcDbDirectory: /var/lib/ldap/dc=poc
olcDbIndex: objectClass eq
olcDbIndex: entryUUID eq
olcDbIndex: entryCSN eq
dn: olcOverlay={0}syncprov,olcDatabase={2}mdb,cn=config
objectClass: olcConfig
objectClass: olcOverlayConfig
objectClass: olcSyncProvConfig
olcSpCheckpoint: 1000 60
olcSpNoPresent: TRUE
olcSpReloadHint: TRUE
dn: olcOverlay={1}syncprov,olcDatabase={2}mdb,cn=config
objectClass: olcConfig
objectClass: olcOverlayConfig
objectClass: olcAccessLogConfig
olcAccessLogDB: cn=accesslog
olcAccessLogOps: writes
olcAccessLogPurge: 07+00:00 01+00:00
@christopherwood
Copy link
Author

For posterity: The accesslog overlay configuration at line 62 specifies the syncprov overlay in the DN, which won't work. When I specify olcOverlay={1}accesslog in the DN line, it works without a segfault. Thank you to Howard Chu for being polite about it in the openldap-technical thread:
http://www.openldap.org/lists/openldap-technical/201708/msg00080.html

@christopherwood
Copy link
Author

The incorrect line in question.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment