Sample ldapadd Command Breakdown
ldapadd -x -D "cn=Manager,dc=sample,dc=com" -W -f example.ldif
ldapadd is installed to
that should be in your command path ($PATH).
-x option tells the command to use simple (user and
password) authentication instead of SASL. Running from the command line
you generally are using simple BIND (authentication).
The -D option tells
ldapadd what directory user is
trying to add data. The command BINDs (logs in as) that user. Here we
are logging in as the “root user” of the directory:
-W option tells
ldapadd to prompt us
for the password. The
-w option lets you put the password
right into the command. We recommend keeping the habit of using
-f option specifies that the LDIF input is coming
from a file and provides the file name.