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

pcache overlay help



i am trying to setup the pcache overlay to cache routinely used entries in the DIT.  using the below, i am able to load the pcache module:

ldapmodify -QY EXTERNAL -H ldapi:///
dn: cn=module,cn=config
changetype:add
objectClass: olcModuleList
cn: module
olcModulePath: /usr/lib64/openldap
olcModuleLoad: pcache.la

then i try to add some caching directives, using the below:

ldapmodify -QY EXTERNAL -H ldapi:///
dn: olcOverlay={0}pcache,olcDatabase={2}hdb,cn=config
changetype: add
objectClass: olcOverlayConfig
objectClass: olcPcacheConfig
objectClass: olcPcacheDatabase
olcOverlay: {0}pcache
olcPcache: hdb 100000 50 1000 100

olcPcacheAttrset: 0 nSRecord sOARecord pTRRecord aRecord cNAMERecord sRVRecord tXTRecord
olcPcacheTemplate: "(zoneName=)" 0 3600
olcPcacheTemplate: "(&(zoneName=)(relativeDomainName=))" 0 3600

olcPcacheAttrset: 1 krbprincipalname krbcanonicalname objectclass krbprincipalkey krbmaxrenewableage krbmaxticketlife krbticketflags krbprincipalexpiration krbticketpolicyreference krbUpEnabled krbpwdpolicyreference krbpasswordexpiration krbLastFailedAuth krbLoginFailedCount krbLastSuccessfulAuth nsaccountlock krbLastPwdChange krbLastAdminUnlock krbExtraData krbObjectReferences krbAllowedToDelegateTo
olcPcacheTemplate: "(&(|(objectClass=)(objectClass=))(krbPrincipalName=))" 1 3600

olcPcacheAttrset: 2 userPassword cn gidNumber uidNumber loginShell objectClass gecos uid homeDirectory
olcPcacheTemplate: "(&(objectClass=)(uid=))" 2 3600

olcPcacheAttrset: 3 cn userPassword memberUid gidNumber uniqueMember
olcPcacheTemplate: "(&(objectClass=)(cn=))" 3 3600
olcPcacheTemplate: "(&(objectClass=)(memberUid=))" 3 3600
olcPcacheTemplate: "(&(objectClass=)(gidNumber=))" 3 3600
olcPcacheTemplate: "(&(objectClass=)(|(memberUid=)(uniqueMember=)))" 3 3600

i no longer have logs around the failure, but the error message indicated that the olcDbDirectory could not be found.  the DN dn: olcDatabase={2}hdb,cn=config has that specified (olcDbDirectory: /var/lib/ldap), but i am missing something about pcache and the backend sharing this directive.  can anyone point me in the right direction about how to get the pcache overlay setup correctly?