Show Table of Contents
9.3. Registering Entry Store/Fetch Functions
The plug-in configuration entry is much like that for other types of plug-ins. The
nsslapd-pluginType is ldbmentryfetchstore. The plug-in init function should register the entry fetch callback using slapi_pblock_set() with SLAPI_PLUGIN_ENTRY_FETCH_FUNC and register the entry store callback using slapi_pblock_set() with SLAPI_PLUGIN_ENTRY_STORE_FUNC. It is not necessary to have both functions; it is possible to use only a fetch or only a store function.
It is also possible to register a start and a close function.
To register an entry store or entry fetch plug-in function, edit the Directory Server's
dse.ldif file configuration file and add the entry:
- Add the plug-in parameters to the
dse.ldiffile. For example:# ldapmodify -D "cn=Directory Manager" -W -p 389 -h server.example.com -x dn: cn=Test entry,cn=plugins,cn=config objectClass: top objectClass: nsSlapdPlugin objectClass: extensibleObject cn: Test entry nsslapd-pluginPath: /path/to/test-plugin.so nsslapd-pluginInitfunc: testentry_init nsslapd-pluginType: ldbmentryfetchstore nsslapd-pluginEnabled: on nsslapd-pluginId: test-entry
- Restart the server to load the new plug-in.
# systemctl restart dirsrv.target
The
testentry.c source file has an example plug-in function that implements entry store and entry fetch operations. Example files are installed in /usr/lib64/dirsrv/plugins.

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.