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

Re: What's the differences between slapadd and ldapadd?

--On Sunday, July 11, 2004 2:06 PM -0700 Howard Chu <hyc@symas.com> wrote:

Quanah Gibson-Mount wrote:

--On Saturday, July 10, 2004 11:24 PM +0800 Wang Penghui
<wangpenghui@realss.com> wrote:

Hi all.

Each of the commands "ldapadd" and "slapadd" could add entries to a
slapd server.
But i could not make clear that what's the differences between them.
When should use "ldapadd" and when should use "slapadd"?
Could someone pick me up a doc about it?

In general:

slapadd is for bulk loading the database.

ldapadd is for adding entries once you have a database.

The fundamental difference is that slapadd operates on the database files. As such, it cannot be used while slapd is running, and it must run on the same machine as the slapd server. ldapadd operates via the LDAP protocol, so it requires a running LDAP server as its target, and that server can be anywhere on the network. You can use ldapadd to populate a new/empty database if you really want to, there's not much performance difference between it and slapadd these days.

There can be based on whether or not you have transaction logging and log file creation enabled though. ;) On a sufficiently fast system (3GHz) it is true I don't see much difference between the two.


Quanah Gibson-Mount
Principal Software Developer
ITSS/Shared Services
Stanford University
GnuPG Public Key: http://www.stanford.edu/~quanah/pgp.html