0

how to can i get all users list on edirectory (or openldap) on opensuse? or make a full backup from openldap database?

Thanks

1

You can ask for every uid in your ldap server with ldapsearch command:

ldapsearch -x -LLL uid=*
0

Making a full backup of your OpenLDAP server is a different thing than getting a user list.

A backup is best made on the server itself using the slapcat utility. slapcat directly reads the backend database files. This way it can make a real full backup fast, including operational attributes which are normally hidden.

However, directly opening the database files also means it can only work on the server where the OpenLDAP daemon (slapd) is located, and slapcat needs to run as root.

The OpenLDAP daemon slapd does not need to run for slapcat to work, but it is OK if it does.

This simple command is often enough to dump a full backup to an LDIF file.

slapcat >/your/backup/file.ldif

But refer to the man page for details if you also want to backup the cn=config database or your setup has more than one LDAP database.

The resulting LDIF file could be used to grep for your user list by the way.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.