[0931098] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[0931098] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[c00932a] | 7 | <!ENTITY openldap-download-http " ">
|
---|
[12949fb] | 8 | <!ENTITY openldap-download-ftp "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/openldap-&openldap-version;.tgz">
|
---|
[4585084d] | 9 | <!ENTITY openldap-md5sum "b0d5ee4b252c841dec6b332d679cf943">
|
---|
[0760f1d] | 10 | <!ENTITY openldap-size "5.3 MB">
|
---|
[4585084d] | 11 | <!ENTITY openldap-buildsize "48 MB (client) 103 MB (server)">
|
---|
| 12 | <!ENTITY openldap-time "0.9 SBU (client) 1.8 SBU (server)">
|
---|
[0931098] | 13 | ]>
|
---|
| 14 |
|
---|
[9a9a0fec] | 15 | <sect1 id="openldap" xreflabel="OpenLDAP-&openldap-version;">
|
---|
[814e53c] | 16 | <?dbhtml filename="openldap.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | </sect1info>
|
---|
| 22 |
|
---|
| 23 | <title>OpenLDAP-&openldap-version;</title>
|
---|
| 24 |
|
---|
| 25 | <indexterm zone="openldap">
|
---|
| 26 | <primary sortas="a-OpenLDAP">OpenLDAP</primary>
|
---|
| 27 | </indexterm>
|
---|
| 28 |
|
---|
| 29 | <sect2 role="package">
|
---|
| 30 | <title>Introduction to OpenLDAP</title>
|
---|
| 31 |
|
---|
[b5e36dd] | 32 | <para>
|
---|
| 33 | The <application>OpenLDAP</application> package provides an open
|
---|
| 34 | source implementation of the Lightweight Directory Access Protocol.
|
---|
| 35 | </para>
|
---|
| 36 |
|
---|
[2f62a072] | 37 | &lfs75_checked;
|
---|
[814e53c] | 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
[b5e36dd] | 42 | <para>
|
---|
| 43 | Download (HTTP): <ulink url="&openldap-download-http;"/>
|
---|
| 44 | </para>
|
---|
[814e53c] | 45 | </listitem>
|
---|
| 46 | <listitem>
|
---|
[b5e36dd] | 47 | <para>
|
---|
| 48 | Download (FTP): <ulink url="&openldap-download-ftp;"/>
|
---|
| 49 | </para>
|
---|
[814e53c] | 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
[b5e36dd] | 52 | <para>
|
---|
| 53 | Download MD5 sum: &openldap-md5sum;
|
---|
| 54 | </para>
|
---|
[814e53c] | 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
[b5e36dd] | 57 | <para>
|
---|
| 58 | Download size: &openldap-size;
|
---|
| 59 | </para>
|
---|
[814e53c] | 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
[b5e36dd] | 62 | <para>
|
---|
| 63 | Estimated disk space required: &openldap-buildsize;
|
---|
| 64 | </para>
|
---|
[814e53c] | 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
[b5e36dd] | 67 | <para>
|
---|
| 68 | Estimated build time: &openldap-time;
|
---|
| 69 | </para>
|
---|
[814e53c] | 70 | </listitem>
|
---|
| 71 | </itemizedlist>
|
---|
| 72 |
|
---|
[6a604251] | 73 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[ba432fd] | 74 | <itemizedlist spacing="compact">
|
---|
| 75 | <listitem>
|
---|
[b5e36dd] | 76 | <para>
|
---|
| 77 | Required patch:
|
---|
[0760f1d] | 78 | <ulink url="&patch-root;/openldap-&openldap-version;-blfs_paths-1.patch"/>
|
---|
[b5e36dd] | 79 | </para>
|
---|
[1ef8da9] | 80 | </listitem>
|
---|
| 81 | <listitem>
|
---|
[b5e36dd] | 82 | <para>
|
---|
| 83 | Required patch:
|
---|
[0760f1d] | 84 | <ulink url="&patch-root;/openldap-&openldap-version;-symbol_versions-1.patch"/>
|
---|
[b5e36dd] | 85 | </para>
|
---|
[1ef8da9] | 86 | </listitem>
|
---|
[2f62a072] | 87 | <!-- <listitem>
|
---|
[b5e36dd] | 88 | <para>
|
---|
| 89 | Optional patch:
|
---|
| 90 | <ulink url="&patch-root;/openldap-&openldap-version;-ntlm-1.patch"/>
|
---|
| 91 | </para>
|
---|
[2f62a072] | 92 | </listitem> -->
|
---|
[ba432fd] | 93 | </itemizedlist>
|
---|
| 94 |
|
---|
[814e53c] | 95 | <bridgehead renderas="sect3">OpenLDAP Dependencies</bridgehead>
|
---|
| 96 |
|
---|
[de7f20e] | 97 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[b5e36dd] | 98 | <para role="required">
|
---|
[74f15e6] | 99 | <xref linkend="db"/> (only if building server)
|
---|
[b5e36dd] | 100 | </para>
|
---|
[814e53c] | 101 |
|
---|
| 102 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
[b5e36dd] | 103 | <para role="recommended">
|
---|
| 104 | <xref linkend="cyrus-sasl"/> and
|
---|
| 105 | <xref linkend="openssl"/>
|
---|
| 106 | </para>
|
---|
[814e53c] | 107 |
|
---|
| 108 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[b5e36dd] | 109 | <para role="optional">
|
---|
| 110 | <xref linkend="icu"/>,
|
---|
[5e0662d] | 111 | <xref linkend="mariadb"/> or
|
---|
| 112 | <ulink url="http://www.mysql.com/">MySQL</ulink> or
|
---|
| 113 | <xref linkend="postgresql"/>,
|
---|
[b5e36dd] | 114 | <ulink url="http://www.openslp.org/">OpenSLP</ulink>,
|
---|
[bc6e56d] | 115 | <xref linkend="pth"/> and
|
---|
[b5e36dd] | 116 | <xref linkend="unixodbc"/>
|
---|
| 117 | </para>
|
---|
[814e53c] | 118 |
|
---|
[3cb0c57] | 119 | <para condition="html" role="usernotes">User Notes:
|
---|
[bc6e56d] | 120 | <ulink url="&blfs-wiki;/openldap"/>
|
---|
| 121 | </para>
|
---|
[814e53c] | 122 | </sect2>
|
---|
| 123 |
|
---|
| 124 | <sect2 role="installation">
|
---|
| 125 | <title>Installation of OpenLDAP</title>
|
---|
| 126 |
|
---|
[2f62a072] | 127 | <!-- <important>
|
---|
[b5e36dd] | 128 | <para>
|
---|
| 129 | Without the following patch, the <application>Evolution</application>
|
---|
[0d7900a] | 130 | Exchange addressbook integration uses simple binds with cleartext
|
---|
| 131 | passwords. If you are going to build
|
---|
[b5e36dd] | 132 | <application>Evolution Data Server</application> with
|
---|
| 133 | <application>OpenLDAP</application> support, apply the following patch:
|
---|
| 134 | </para>
|
---|
[c00932a] | 135 |
|
---|
| 136 | <screen><userinput>patch -Np1 -i ../openldap-&openldap-version;-ntlm-1.patch</userinput></screen>
|
---|
[2f62a072] | 137 | </important> -->
|
---|
[c00932a] | 138 |
|
---|
[12949fb] | 139 | <note>
|
---|
[b5e36dd] | 140 | <para>
|
---|
| 141 | If you only need to install the client side <command>ldap*</command>
|
---|
| 142 | binaries, corresponding man pages, libraries and header files (referred to
|
---|
[9ef1b6ff] | 143 | as a <quote>client-only</quote> install), issue these
|
---|
| 144 | commands instead of the following ones (no test suite available):
|
---|
[b5e36dd] | 145 | </para>
|
---|
[12949fb] | 146 |
|
---|
[0760f1d] | 147 | <screen><userinput>patch -Np1 -i ../openldap-&openldap-version;-blfs_paths-1.patch &&
|
---|
| 148 | patch -Np1 -i ../openldap-&openldap-version;-symbol_versions-1.patch &&
|
---|
[439e942e] | 149 | autoconf &&
|
---|
[d6da5da] | 150 | ./configure --prefix=/usr \
|
---|
[12949fb] | 151 | --sysconfdir=/etc \
|
---|
[9ef1b6ff] | 152 | --disable-static \
|
---|
[d6da5da] | 153 | --enable-dynamic \
|
---|
| 154 | --disable-debug \
|
---|
| 155 | --disable-slapd &&
|
---|
| 156 | make depend &&
|
---|
[c612fc3] | 157 | make</userinput></screen>
|
---|
| 158 |
|
---|
| 159 | <para>
|
---|
| 160 | Then, as the <systemitem class="username">root</systemitem> user:
|
---|
| 161 | </para>
|
---|
| 162 |
|
---|
| 163 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
[9ef1b6ff] | 164 |
|
---|
[12949fb] | 165 | </note>
|
---|
| 166 |
|
---|
[b194f2b] | 167 | <para>
|
---|
| 168 | There should be a dedicated user and group to take control
|
---|
| 169 | of the <command>slapd</command> daemon after it is
|
---|
| 170 | started. Issue the following commands as the
|
---|
| 171 | <systemitem class="username">root</systemitem> user:
|
---|
| 172 | </para>
|
---|
| 173 |
|
---|
| 174 | <screen role="root"><userinput>groupadd -g 83 ldap &&
|
---|
| 175 | useradd -c "OpenLDAP Daemon Owner" -d /var/lib/openldap -u 83 \
|
---|
| 176 | -g ldap -s /bin/false ldap</userinput></screen>
|
---|
| 177 |
|
---|
[b5e36dd] | 178 | <para>
|
---|
| 179 | Install <application>OpenLDAP</application> by
|
---|
| 180 | running the following commands:
|
---|
| 181 | </para>
|
---|
[814e53c] | 182 |
|
---|
[0760f1d] | 183 | <screen><userinput>patch -Np1 -i ../openldap-&openldap-version;-blfs_paths-1.patch &&
|
---|
| 184 | patch -Np1 -i ../openldap-&openldap-version;-symbol_versions-1.patch &&
|
---|
[439e942e] | 185 | autoconf &&
|
---|
[d6da5da] | 186 | ./configure --prefix=/usr \
|
---|
| 187 | --sysconfdir=/etc \
|
---|
| 188 | --localstatedir=/var \
|
---|
[c00932a] | 189 | --libexecdir=/usr/lib \
|
---|
[d6da5da] | 190 | --disable-static \
|
---|
| 191 | --disable-debug \
|
---|
| 192 | --enable-dynamic \
|
---|
| 193 | --enable-crypt \
|
---|
| 194 | --enable-spasswd \
|
---|
| 195 | --enable-modules \
|
---|
| 196 | --enable-rlookups \
|
---|
[c00932a] | 197 | --enable-backends=mod \
|
---|
| 198 | --enable-overlays=mod \
|
---|
[d6da5da] | 199 | --disable-ndb \
|
---|
[b895aa3] | 200 | --disable-sql &&
|
---|
[0931098] | 201 | make depend &&
|
---|
[d9091faa] | 202 | make</userinput></screen>
|
---|
| 203 |
|
---|
[b5e36dd] | 204 | <para>
|
---|
[4585084d] | 205 | To test the results, issue: <command>make test</command>. Tests may fail
|
---|
| 206 | after a long time (~ 5 SBU).
|
---|
[b5e36dd] | 207 | </para>
|
---|
[814e53c] | 208 |
|
---|
[b5e36dd] | 209 | <para>
|
---|
| 210 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 211 | </para>
|
---|
[814e53c] | 212 |
|
---|
| 213 | <screen role="root"><userinput>make install &&
|
---|
[0c74155e] | 214 |
|
---|
[117309d] | 215 | chmod -v 700 /var/lib/openldap &&
|
---|
[c612fc3] | 216 | chown -v -R root:ldap /var/lib/openldap &&
|
---|
[117309d] | 217 | chmod -v 640 /etc/openldap/{slapd.{conf,ldif},DB_CONFIG.example} &&
|
---|
| 218 | chown -v root:ldap /etc/openldap/{slapd.{conf,ldif},DB_CONFIG.example} &&
|
---|
| 219 | install -v -dm700 -o ldap -g ldap /etc/openldap/slapd.d &&
|
---|
[b194f2b] | 220 |
|
---|
[d6da5da] | 221 | install -v -dm755 /usr/share/doc/openldap-&openldap-version; &&
|
---|
[1ef8da9] | 222 | cp -vfr doc/drafts /usr/share/doc/openldap-&openldap-version; &&
|
---|
| 223 | cp -vfr doc/rfc /usr/share/doc/openldap-&openldap-version; &&
|
---|
| 224 | cp -vfr doc/guide /usr/share/doc/openldap-&openldap-version;</userinput></screen>
|
---|
[814e53c] | 225 |
|
---|
[117309d] | 226 | <para>
|
---|
| 227 | Having slapd configuration files and ldap databases in /var/lib/openldap
|
---|
| 228 | readable by anyone is a SECURITY ISSUE, especially since a file stores
|
---|
| 229 | admin password in PLAIN TEXT. That's why mode 640 and root:ldap ownership
|
---|
| 230 | were used. Owner is root, so only root can modify the file, and group is
|
---|
| 231 | ldap, so that the group which owns slapd daemon could read but not modify
|
---|
| 232 | the file in case of a security breach.
|
---|
| 233 | </para>
|
---|
| 234 |
|
---|
[814e53c] | 235 | </sect2>
|
---|
| 236 |
|
---|
| 237 | <sect2 role="commands">
|
---|
| 238 | <title>Command Explanations</title>
|
---|
| 239 |
|
---|
[c00932a] | 240 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
[b5e36dd] | 241 | href="../../xincludes/static-libraries.xml"/>
|
---|
| 242 |
|
---|
| 243 | <para>
|
---|
[9ef1b6ff] | 244 | <parameter>--disable-debug</parameter>: This switch disables
|
---|
[b5e36dd] | 245 | the debugging code in <application>OpenLDAP</application>.
|
---|
| 246 | </para>
|
---|
| 247 |
|
---|
| 248 | <para>
|
---|
[9ef1b6ff] | 249 | <parameter>--enable-dynamic</parameter>: This switch forces the
|
---|
[b5e36dd] | 250 | <application>OpenLDAP</application> libraries to be dynamically
|
---|
| 251 | linked to the executable programs.
|
---|
| 252 | </para>
|
---|
| 253 |
|
---|
| 254 | <para>
|
---|
[9ef1b6ff] | 255 | <parameter>--enable-crypt</parameter>: This switch enables using of
|
---|
[b5e36dd] | 256 | <command>crypt(3)</command> passwords.
|
---|
| 257 | </para>
|
---|
| 258 |
|
---|
| 259 | <para>
|
---|
[9ef1b6ff] | 260 | <parameter>--enable-spasswd</parameter>: This switch enables
|
---|
[d6da5da] | 261 | <application>SASL</application> password verification.
|
---|
| 262 | </para>
|
---|
| 263 |
|
---|
| 264 | <para>
|
---|
[9ef1b6ff] | 265 | <parameter>--enable-modules</parameter>: This switch enables dynamic
|
---|
[b5e36dd] | 266 | module support.
|
---|
| 267 | </para>
|
---|
| 268 |
|
---|
| 269 | <para>
|
---|
[9ef1b6ff] | 270 | <parameter>--enable-rlookups</parameter>: This switch enables
|
---|
[b5e36dd] | 271 | reverse lookups of client hostnames.
|
---|
| 272 | </para>
|
---|
| 273 |
|
---|
| 274 | <para>
|
---|
[9ef1b6ff] | 275 | <parameter>--enable-backends</parameter>: This switch enables
|
---|
[b5e36dd] | 276 | all available backends.
|
---|
| 277 | </para>
|
---|
| 278 |
|
---|
| 279 | <para>
|
---|
[9ef1b6ff] | 280 | <parameter>--enable-overlays</parameter>: This switch enables
|
---|
[b5e36dd] | 281 | all available overlays.
|
---|
| 282 | </para>
|
---|
| 283 |
|
---|
| 284 | <para>
|
---|
[9ef1b6ff] | 285 | <parameter>--disable-ndb</parameter>: This switch disables
|
---|
[0d7900a] | 286 | <application>MySQL</application> NDB Cluster backend
|
---|
[b5e36dd] | 287 | which causes configure to fail if
|
---|
| 288 | <application>MySQL</application> is present.
|
---|
| 289 | </para>
|
---|
| 290 |
|
---|
| 291 | <para>
|
---|
[9ef1b6ff] | 292 | <parameter>--disable-sql</parameter>: This switch explicitly
|
---|
[b5e36dd] | 293 | disables the SQL backend. Omit this switch if a SQL server is
|
---|
| 294 | installed and you are going to use a SQL backend.
|
---|
| 295 | </para>
|
---|
| 296 |
|
---|
[67bd7d46] | 297 | <para>
|
---|
| 298 | <parameter>--libexecdir=/usr/lib</parameter>: This switch controls where
|
---|
| 299 | the <filename class="directory">/usr/lib/openldap</filename> directory is
|
---|
| 300 | installed. Everything in that directory is a library, so it belongs under
|
---|
| 301 | <filename class="directory">/usr/lib</filename> instead of
|
---|
| 302 | <filename class="directory">/usr/libexec</filename>.
|
---|
| 303 | </para>
|
---|
| 304 |
|
---|
[b5e36dd] | 305 | <para>
|
---|
[d6da5da] | 306 | <option>--enable-slp</option>: This switch enables
|
---|
| 307 | SLPv2 support. Use it if you have installed
|
---|
[b5e36dd] | 308 | <ulink url="http://www.openslp.org/">OpenSLP</ulink>.
|
---|
| 309 | </para>
|
---|
[516a4acd] | 310 |
|
---|
| 311 | <note>
|
---|
[b5e36dd] | 312 | <para>
|
---|
| 313 | You can run <command>./configure --help</command> to see if there
|
---|
[d6da5da] | 314 | are other switch you can pass to the <command>configure</command>
|
---|
[b5e36dd] | 315 | command to enable other options or dependency packages.
|
---|
| 316 | </para>
|
---|
[516a4acd] | 317 | </note>
|
---|
| 318 |
|
---|
[814e53c] | 319 | </sect2>
|
---|
| 320 |
|
---|
| 321 | <sect2 role="configuration">
|
---|
| 322 | <title>Configuring OpenLDAP</title>
|
---|
| 323 |
|
---|
| 324 | <sect3 id="openldap-config">
|
---|
| 325 | <title>Config Files</title>
|
---|
| 326 |
|
---|
[bc6e56d] | 327 | <para>
|
---|
| 328 | <filename>/etc/openldap/*</filename>
|
---|
| 329 | </para>
|
---|
[814e53c] | 330 |
|
---|
| 331 | <indexterm zone="openldap openldap-config">
|
---|
[bc6e56d] | 332 | <primary sortas="e-etc-openldap">/etc/openldap/*</primary>
|
---|
[814e53c] | 333 | </indexterm>
|
---|
| 334 |
|
---|
| 335 | </sect3>
|
---|
| 336 |
|
---|
| 337 | <sect3>
|
---|
| 338 | <title>Configuration Information</title>
|
---|
| 339 |
|
---|
[b5e36dd] | 340 | <para>
|
---|
| 341 | Configuring the <command>slapd</command> servers can be complex.
|
---|
| 342 | Securing the LDAP directory, especially if you are storing non-public
|
---|
| 343 | data such as password databases, can also be a challenging task. You'll
|
---|
| 344 | need to modify the <filename>/etc/openldap/slapd.conf</filename> and
|
---|
| 345 | <filename>/etc/openldap/ldap.conf</filename> files to set up
|
---|
| 346 | <application>OpenLDAP</application> for your particular needs.
|
---|
| 347 | </para>
|
---|
[814e53c] | 348 |
|
---|
| 349 | <indexterm zone="openldap openldap-config">
|
---|
| 350 | <primary
|
---|
| 351 | sortas="e-etc-openldap-slapd.conf">/etc/openldap/slapd.conf</primary>
|
---|
| 352 | </indexterm>
|
---|
| 353 |
|
---|
| 354 | <indexterm zone="openldap openldap-config">
|
---|
| 355 | <primary
|
---|
| 356 | sortas="e-etc-openldap-ldap.conf">/etc/openldap/ldap.conf</primary>
|
---|
| 357 | </indexterm>
|
---|
| 358 |
|
---|
[bc6e56d] | 359 | <para>
|
---|
| 360 | Resources to assist you with topics such as choosing a directory
|
---|
| 361 | configuration, backend and database definitions, access control settings,
|
---|
| 362 | running as a user other than <systemitem class="username">root</systemitem>
|
---|
| 363 | and setting a <command>chroot</command> environment include:
|
---|
| 364 | </para>
|
---|
[814e53c] | 365 |
|
---|
[d6da5da] | 366 | <itemizedlist spacing="compact">
|
---|
[814e53c] | 367 | <listitem>
|
---|
[b5e36dd] | 368 | <para>
|
---|
| 369 | The <command>slapd</command> man page.
|
---|
| 370 | </para>
|
---|
[814e53c] | 371 | </listitem>
|
---|
| 372 | <listitem>
|
---|
[b5e36dd] | 373 | <para>
|
---|
| 374 | The <filename>slapd.conf</filename> man page.
|
---|
| 375 | </para>
|
---|
[814e53c] | 376 | </listitem>
|
---|
| 377 | <listitem>
|
---|
[b5e36dd] | 378 | <para>
|
---|
| 379 | The <ulink url="http://www.openldap.org/doc/admin24/">
|
---|
[0d7900a] | 380 | OpenLDAP 2.4 Administrator's Guide</ulink>
|
---|
[b5e36dd] | 381 | (also installed locally in <filename class='directory'>
|
---|
| 382 | /usr/share/doc/openldap-&openldap-version;/guide/admin</filename>).
|
---|
| 383 | </para>
|
---|
[814e53c] | 384 | </listitem>
|
---|
| 385 | <listitem>
|
---|
[b5e36dd] | 386 | <para>
|
---|
| 387 | Documents located at
|
---|
| 388 | <ulink url="http://www.openldap.org/pub/"/>.
|
---|
| 389 | </para>
|
---|
[814e53c] | 390 | </listitem>
|
---|
| 391 | </itemizedlist>
|
---|
| 392 |
|
---|
| 393 | </sect3>
|
---|
| 394 |
|
---|
| 395 | <sect3>
|
---|
| 396 | <title>Mozilla Address Directory</title>
|
---|
| 397 |
|
---|
[b5e36dd] | 398 | <para>
|
---|
| 399 | By default, LDAPv2 support is disabled in the
|
---|
| 400 | <filename>slapd.conf</filename> file. Once the database is properly
|
---|
| 401 | set up and <application>Mozilla</application> is configured to use the
|
---|
| 402 | directory, you must add <option>allow bind_v2</option> to the
|
---|
| 403 | <filename>slapd.conf</filename> file.
|
---|
| 404 | </para>
|
---|
[814e53c] | 405 |
|
---|
| 406 | </sect3>
|
---|
| 407 |
|
---|
| 408 | <sect3 id="openldap-init">
|
---|
[6bc9f487] | 409 | <title>Systemd Units</title>
|
---|
[814e53c] | 410 |
|
---|
[b5e36dd] | 411 | <para>
|
---|
[6bc9f487] | 412 | To start the <command>slapd</command> daemon at boot,
|
---|
| 413 | install the systemd unit from the <xref linkend="bootscripts"/>
|
---|
| 414 | package by running the following command as the
|
---|
| 415 | <systemitem class="username">root</systemitem> user:
|
---|
[b5e36dd] | 416 | </para>
|
---|
[814e53c] | 417 |
|
---|
| 418 | <indexterm zone="openldap openldap-init">
|
---|
[d9d26317] | 419 | <primary sortas="f-slapd">slapd</primary>
|
---|
[814e53c] | 420 | </indexterm>
|
---|
| 421 |
|
---|
[d9d26317] | 422 | <screen role="root"><userinput>make install-slapd</userinput></screen>
|
---|
[814e53c] | 423 |
|
---|
| 424 | <note>
|
---|
[b5e36dd] | 425 | <para>
|
---|
[0d7900a] | 426 | You'll need to modify the
|
---|
[6bc9f487] | 427 | <filename>/etc/default/slapd</filename> to include the
|
---|
[0d7900a] | 428 | parameters needed for your specific configuration. See the
|
---|
[b5e36dd] | 429 | <command>slapd</command> man page for parameter information.
|
---|
| 430 | </para>
|
---|
[814e53c] | 431 | </note>
|
---|
| 432 |
|
---|
| 433 | </sect3>
|
---|
| 434 |
|
---|
| 435 | <sect3>
|
---|
| 436 | <title>Testing the Configuration</title>
|
---|
| 437 |
|
---|
[b5e36dd] | 438 | <para>
|
---|
[6bc9f487] | 439 | Start the LDAP server using <command>systemctl</command>:
|
---|
[b5e36dd] | 440 | </para>
|
---|
[814e53c] | 441 |
|
---|
[6bc9f487] | 442 | <screen role="root"><userinput>systemctl start slapd</userinput></screen>
|
---|
[814e53c] | 443 |
|
---|
[b5e36dd] | 444 | <para>
|
---|
| 445 | Verify access to the LDAP server with the following command:
|
---|
| 446 | </para>
|
---|
[814e53c] | 447 |
|
---|
| 448 | <screen><userinput>ldapsearch -x -b '' -s base '(objectclass=*)' namingContexts</userinput></screen>
|
---|
| 449 |
|
---|
[b5e36dd] | 450 | <para>
|
---|
| 451 | The expected result is:
|
---|
| 452 | </para>
|
---|
[814e53c] | 453 |
|
---|
[0931098] | 454 | <screen><computeroutput># extended LDIF
|
---|
| 455 | #
|
---|
| 456 | # LDAPv3
|
---|
| 457 | # base <> with scope base
|
---|
| 458 | # filter: (objectclass=*)
|
---|
[814e53c] | 459 | # requesting: namingContexts
|
---|
[0931098] | 460 | #
|
---|
| 461 |
|
---|
| 462 | #
|
---|
| 463 | dn:
|
---|
| 464 | namingContexts: dc=my-domain,dc=com
|
---|
| 465 |
|
---|
| 466 | # search result
|
---|
| 467 | search: 2
|
---|
| 468 | result: 0 Success
|
---|
| 469 |
|
---|
| 470 | # numResponses: 2
|
---|
| 471 | # numEntries: 1</computeroutput></screen>
|
---|
| 472 |
|
---|
[814e53c] | 473 | </sect3>
|
---|
| 474 |
|
---|
| 475 | </sect2>
|
---|
| 476 |
|
---|
| 477 | <sect2 role="content">
|
---|
| 478 | <title>Contents</title>
|
---|
| 479 |
|
---|
| 480 | <segmentedlist>
|
---|
| 481 | <segtitle>Installed Programs</segtitle>
|
---|
| 482 | <segtitle>Installed Libraries</segtitle>
|
---|
| 483 | <segtitle>Installed Directories</segtitle>
|
---|
| 484 |
|
---|
| 485 | <seglistitem>
|
---|
[b5e36dd] | 486 | <seg>
|
---|
| 487 | ldapadd, ldapcompare, ldapdelete, ldapexop, ldapmodify, ldapmodrdn,
|
---|
[4585084d] | 488 | ldappasswd, ldapsearch, ldapurl, ldapwhoami, slapacl, slapadd,
|
---|
| 489 | slapauth, slapcat, slapd, slapdn, slapindex, slappasswd, slapschema,
|
---|
| 490 | and slaptest
|
---|
[b5e36dd] | 491 | </seg>
|
---|
| 492 | <seg>
|
---|
[4585084d] | 493 | liblber.so, libldap.so, libldap_r.so,
|
---|
| 494 | and several under /usr/lib/openldap
|
---|
[b5e36dd] | 495 | </seg>
|
---|
| 496 | <seg>
|
---|
| 497 | /etc/openldap,
|
---|
[4585084d] | 498 | /usr/lib/openldap,
|
---|
| 499 | /usr/share/doc/openldap-&openldap-version;, and
|
---|
[b5e36dd] | 500 | /var/lib/openldap
|
---|
| 501 | </seg>
|
---|
[814e53c] | 502 | </seglistitem>
|
---|
| 503 | </segmentedlist>
|
---|
| 504 |
|
---|
| 505 | <variablelist>
|
---|
| 506 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 507 | <?dbfo list-presentation="list"?>
|
---|
| 508 | <?dbhtml list-presentation="table"?>
|
---|
| 509 |
|
---|
| 510 | <varlistentry id="ldapadd">
|
---|
| 511 | <term><command>ldapadd</command></term>
|
---|
| 512 | <listitem>
|
---|
[b5e36dd] | 513 | <para>
|
---|
| 514 | opens a connection to an LDAP server, binds and adds entries.
|
---|
| 515 | </para>
|
---|
[814e53c] | 516 | <indexterm zone="openldap ldapadd">
|
---|
| 517 | <primary sortas="b-ldapadd">ldapadd</primary>
|
---|
| 518 | </indexterm>
|
---|
| 519 | </listitem>
|
---|
| 520 | </varlistentry>
|
---|
| 521 |
|
---|
| 522 | <varlistentry id="ldapcompare">
|
---|
| 523 | <term><command>ldapcompare</command></term>
|
---|
| 524 | <listitem>
|
---|
[b5e36dd] | 525 | <para>
|
---|
| 526 | opens a connection to an LDAP server, binds and performs
|
---|
| 527 | a compare using specified parameters.
|
---|
| 528 | </para>
|
---|
[814e53c] | 529 | <indexterm zone="openldap ldapcompare">
|
---|
| 530 | <primary sortas="b-ldapcompare">ldapcompare</primary>
|
---|
| 531 | </indexterm>
|
---|
| 532 | </listitem>
|
---|
| 533 | </varlistentry>
|
---|
| 534 |
|
---|
| 535 | <varlistentry id="ldapdelete">
|
---|
| 536 | <term><command>ldapdelete</command></term>
|
---|
| 537 | <listitem>
|
---|
[b5e36dd] | 538 | <para>
|
---|
| 539 | opens a connection to an LDAP server, binds and deletes
|
---|
| 540 | one or more entries.
|
---|
| 541 | </para>
|
---|
[814e53c] | 542 | <indexterm zone="openldap ldapdelete">
|
---|
| 543 | <primary sortas="b-ldapdelete">ldapdelete</primary>
|
---|
| 544 | </indexterm>
|
---|
| 545 | </listitem>
|
---|
| 546 | </varlistentry>
|
---|
| 547 |
|
---|
[c00932a] | 548 | <varlistentry id="ldapexop">
|
---|
| 549 | <term><command>ldapexop</command></term>
|
---|
| 550 | <listitem>
|
---|
[b5e36dd] | 551 | <para>
|
---|
[0d7900a] | 552 | issues the LDAP extended operation specified by
|
---|
[b5e36dd] | 553 | oid or one of the special keywords whoami,
|
---|
| 554 | cancel, or refresh.
|
---|
| 555 | </para>
|
---|
[c00932a] | 556 | <indexterm zone="openldap ldapexop">
|
---|
| 557 | <primary sortas="b-ldapexop">ldapexop</primary>
|
---|
| 558 | </indexterm>
|
---|
| 559 | </listitem>
|
---|
| 560 | </varlistentry>
|
---|
| 561 |
|
---|
[814e53c] | 562 | <varlistentry id="ldapmodify">
|
---|
| 563 | <term><command>ldapmodify</command></term>
|
---|
| 564 | <listitem>
|
---|
[b5e36dd] | 565 | <para>
|
---|
| 566 | opens a connection to an LDAP server, binds and modifies entries.
|
---|
| 567 | </para>
|
---|
[814e53c] | 568 | <indexterm zone="openldap ldapmodify">
|
---|
| 569 | <primary sortas="b-ldapmodify">ldapmodify</primary>
|
---|
| 570 | </indexterm>
|
---|
| 571 | </listitem>
|
---|
| 572 | </varlistentry>
|
---|
| 573 |
|
---|
| 574 | <varlistentry id="ldapmodrdn">
|
---|
| 575 | <term><command>ldapmodrdn</command></term>
|
---|
| 576 | <listitem>
|
---|
[b5e36dd] | 577 | <para>
|
---|
| 578 | opens a connection to an LDAP server, binds and modifies
|
---|
| 579 | the RDN of entries.
|
---|
| 580 | </para>
|
---|
[814e53c] | 581 | <indexterm zone="openldap ldapmodrdn">
|
---|
| 582 | <primary sortas="b-ldapmodrdn">ldapmodrdn</primary>
|
---|
| 583 | </indexterm>
|
---|
| 584 | </listitem>
|
---|
| 585 | </varlistentry>
|
---|
| 586 |
|
---|
| 587 | <varlistentry id="ldappasswd">
|
---|
| 588 | <term><command>ldappasswd</command></term>
|
---|
| 589 | <listitem>
|
---|
[b5e36dd] | 590 | <para>
|
---|
| 591 | is a tool used to set the password of an LDAP user.
|
---|
| 592 | </para>
|
---|
[814e53c] | 593 | <indexterm zone="openldap ldappasswd">
|
---|
| 594 | <primary sortas="b-ldappasswd">ldappasswd</primary>
|
---|
| 595 | </indexterm>
|
---|
| 596 | </listitem>
|
---|
| 597 | </varlistentry>
|
---|
| 598 |
|
---|
| 599 | <varlistentry id="ldapsearch">
|
---|
| 600 | <term><command>ldapsearch</command></term>
|
---|
| 601 | <listitem>
|
---|
[b5e36dd] | 602 | <para>
|
---|
| 603 | opens a connection to an LDAP server, binds and performs
|
---|
| 604 | a search using specified parameters.
|
---|
| 605 | </para>
|
---|
[814e53c] | 606 | <indexterm zone="openldap ldapsearch">
|
---|
| 607 | <primary sortas="b-ldapsearch">ldapsearch</primary>
|
---|
| 608 | </indexterm>
|
---|
| 609 | </listitem>
|
---|
| 610 | </varlistentry>
|
---|
| 611 |
|
---|
[c00932a] | 612 | <varlistentry id="ldapurl">
|
---|
| 613 | <term><command>ldapurl</command></term>
|
---|
| 614 | <listitem>
|
---|
[b5e36dd] | 615 | <para>
|
---|
[0d7900a] | 616 | is a command that allows to either compose or
|
---|
[b5e36dd] | 617 | decompose LDAP URIs.
|
---|
| 618 | </para>
|
---|
[c00932a] | 619 | <indexterm zone="openldap ldapurl">
|
---|
| 620 | <primary sortas="b-ldapurl">ldapurl</primary>
|
---|
| 621 | </indexterm>
|
---|
| 622 | </listitem>
|
---|
| 623 | </varlistentry>
|
---|
| 624 |
|
---|
[814e53c] | 625 | <varlistentry id="ldapwhoami">
|
---|
| 626 | <term><command>ldapwhoami</command></term>
|
---|
| 627 | <listitem>
|
---|
[b5e36dd] | 628 | <para>
|
---|
| 629 | opens a connection to an LDAP server, binds and displays
|
---|
| 630 | whoami information.
|
---|
| 631 | </para>
|
---|
[814e53c] | 632 | <indexterm zone="openldap ldapwhoami">
|
---|
| 633 | <primary sortas="b-ldapwhoami">ldapwhoami</primary>
|
---|
| 634 | </indexterm>
|
---|
| 635 | </listitem>
|
---|
| 636 | </varlistentry>
|
---|
| 637 |
|
---|
[c00932a] | 638 | <varlistentry id="slapacl">
|
---|
| 639 | <term><command>slapacl</command></term>
|
---|
| 640 | <listitem>
|
---|
[b5e36dd] | 641 | <para>
|
---|
[0d7900a] | 642 | is used to check the behavior of slapd by verifying
|
---|
| 643 | access to directory data according to the access control
|
---|
[b5e36dd] | 644 | list directives defined in its configuration.
|
---|
| 645 | </para>
|
---|
[c00932a] | 646 | <indexterm zone="openldap slapacl">
|
---|
| 647 | <primary sortas="b-slapacl">slapacl</primary>
|
---|
| 648 | </indexterm>
|
---|
| 649 | </listitem>
|
---|
| 650 | </varlistentry>
|
---|
| 651 |
|
---|
[814e53c] | 652 | <varlistentry id="slapadd">
|
---|
| 653 | <term><command>slapadd</command></term>
|
---|
| 654 | <listitem>
|
---|
[b5e36dd] | 655 | <para>
|
---|
| 656 | is used to add entries specified in LDAP Directory Interchange
|
---|
| 657 | Format (LDIF) to an LDAP database.
|
---|
| 658 | </para>
|
---|
[814e53c] | 659 | <indexterm zone="openldap slapadd">
|
---|
| 660 | <primary sortas="b-slapadd">slapadd</primary>
|
---|
| 661 | </indexterm>
|
---|
| 662 | </listitem>
|
---|
| 663 | </varlistentry>
|
---|
| 664 |
|
---|
[c00932a] | 665 | <varlistentry id="slapauth">
|
---|
| 666 | <term><command>slapauth</command></term>
|
---|
| 667 | <listitem>
|
---|
[b5e36dd] | 668 | <para>
|
---|
[0d7900a] | 669 | is used to check the behavior of the slapd
|
---|
[b5e36dd] | 670 | in mapping identities for authentication and
|
---|
| 671 | authorization purposes, as specified in slapd.conf.
|
---|
| 672 | </para>
|
---|
[c00932a] | 673 | <indexterm zone="openldap slapauth">
|
---|
| 674 | <primary sortas="b-slapauth">slapauth</primary>
|
---|
| 675 | </indexterm>
|
---|
| 676 | </listitem>
|
---|
| 677 | </varlistentry>
|
---|
| 678 |
|
---|
[814e53c] | 679 | <varlistentry id="slapcat">
|
---|
| 680 | <term><command>slapcat</command></term>
|
---|
| 681 | <listitem>
|
---|
[b5e36dd] | 682 | <para>
|
---|
| 683 | is used to generate an LDAP LDIF output based upon the
|
---|
| 684 | contents of a slapd database.
|
---|
| 685 | </para>
|
---|
[814e53c] | 686 | <indexterm zone="openldap slapcat">
|
---|
| 687 | <primary sortas="b-slapcat">slapcat</primary>
|
---|
| 688 | </indexterm>
|
---|
| 689 | </listitem>
|
---|
| 690 | </varlistentry>
|
---|
| 691 |
|
---|
| 692 | <varlistentry id="slapd">
|
---|
| 693 | <term><command>slapd</command></term>
|
---|
| 694 | <listitem>
|
---|
[b5e36dd] | 695 | <para>
|
---|
| 696 | is the standalone LDAP server.
|
---|
| 697 | </para>
|
---|
[814e53c] | 698 | <indexterm zone="openldap slapd">
|
---|
| 699 | <primary sortas="b-slapd">slapd</primary>
|
---|
| 700 | </indexterm>
|
---|
| 701 | </listitem>
|
---|
| 702 | </varlistentry>
|
---|
| 703 |
|
---|
| 704 | <varlistentry id="slapdn">
|
---|
| 705 | <term><command>slapdn</command></term>
|
---|
| 706 | <listitem>
|
---|
[b5e36dd] | 707 | <para>
|
---|
| 708 | checks a list of string-represented DNs based on schema syntax.
|
---|
| 709 | </para>
|
---|
[814e53c] | 710 | <indexterm zone="openldap slapdn">
|
---|
| 711 | <primary sortas="b-slapdn">slapdn</primary>
|
---|
| 712 | </indexterm>
|
---|
| 713 | </listitem>
|
---|
| 714 | </varlistentry>
|
---|
| 715 |
|
---|
| 716 | <varlistentry id="slapindex">
|
---|
| 717 | <term><command>slapindex</command></term>
|
---|
| 718 | <listitem>
|
---|
[b5e36dd] | 719 | <para>
|
---|
| 720 | is used to regenerate slapd indexes based upon the current
|
---|
| 721 | contents of a database.
|
---|
| 722 | </para>
|
---|
[814e53c] | 723 | <indexterm zone="openldap slapindex">
|
---|
| 724 | <primary sortas="b-slapindex">slapindex</primary>
|
---|
| 725 | </indexterm>
|
---|
| 726 | </listitem>
|
---|
| 727 | </varlistentry>
|
---|
| 728 |
|
---|
| 729 | <varlistentry id="slappasswd">
|
---|
| 730 | <term><command>slappasswd</command></term>
|
---|
| 731 | <listitem>
|
---|
[b5e36dd] | 732 | <para>
|
---|
| 733 | is an <application>OpenLDAP</application> password utility.
|
---|
| 734 | </para>
|
---|
[814e53c] | 735 | <indexterm zone="openldap slappasswd">
|
---|
| 736 | <primary sortas="b-slappasswd">slappasswd</primary>
|
---|
| 737 | </indexterm>
|
---|
| 738 | </listitem>
|
---|
| 739 | </varlistentry>
|
---|
| 740 |
|
---|
[c00932a] | 741 | <varlistentry id="slapschema">
|
---|
| 742 | <term><command>slapschema</command></term>
|
---|
| 743 | <listitem>
|
---|
[b5e36dd] | 744 | <para>
|
---|
[0d7900a] | 745 | is used to check schema compliance of the contents
|
---|
[b5e36dd] | 746 | of a slapd database.
|
---|
| 747 | </para>
|
---|
[c00932a] | 748 | <indexterm zone="openldap slapschema">
|
---|
| 749 | <primary sortas="b-slapschema">slapschema</primary>
|
---|
| 750 | </indexterm>
|
---|
| 751 | </listitem>
|
---|
| 752 | </varlistentry>
|
---|
| 753 |
|
---|
[814e53c] | 754 | <varlistentry id="slaptest">
|
---|
| 755 | <term><command>slaptest</command></term>
|
---|
| 756 | <listitem>
|
---|
[b5e36dd] | 757 | <para>
|
---|
| 758 | checks the sanity of the <filename>slapd.conf</filename> file.
|
---|
| 759 | </para>
|
---|
[814e53c] | 760 | <indexterm zone="openldap slaptest">
|
---|
| 761 | <primary sortas="b-slaptest">slaptest</primary>
|
---|
| 762 | </indexterm>
|
---|
| 763 | </listitem>
|
---|
| 764 | </varlistentry>
|
---|
| 765 |
|
---|
| 766 | <varlistentry id="liblber">
|
---|
[d6da5da] | 767 | <term><filename class="libraryfile">liblber.so</filename></term>
|
---|
[814e53c] | 768 | <listitem>
|
---|
[b5e36dd] | 769 | <para>
|
---|
[1ef8da9] | 770 | is a set of Lightweight Basic Encoding Rules routines. These
|
---|
[b5e36dd] | 771 | routines are used by the LDAP library routines to encode and decode
|
---|
| 772 | LDAP protocol elements using the (slightly simplified) Basic
|
---|
| 773 | Encoding Rules defined by LDAP. They are not normally used directly
|
---|
| 774 | by an LDAP application program except in the handling of controls
|
---|
| 775 | and extended operations.
|
---|
| 776 | </para>
|
---|
[814e53c] | 777 | <indexterm zone="openldap liblber">
|
---|
[c00932a] | 778 | <primary sortas="c-liblber">liblber.so</primary>
|
---|
[814e53c] | 779 | </indexterm>
|
---|
| 780 | </listitem>
|
---|
| 781 | </varlistentry>
|
---|
| 782 |
|
---|
| 783 | <varlistentry id="libldap">
|
---|
[d6da5da] | 784 | <term><filename class="libraryfile">libldap.so</filename></term>
|
---|
[814e53c] | 785 | <listitem>
|
---|
[b5e36dd] | 786 | <para>
|
---|
| 787 | supports the LDAP programs and provide functionality for
|
---|
| 788 | other programs interacting with LDAP.
|
---|
| 789 | </para>
|
---|
[814e53c] | 790 | <indexterm zone="openldap libldap">
|
---|
[c00932a] | 791 | <primary sortas="c-libldap">libldap.so</primary>
|
---|
[814e53c] | 792 | </indexterm>
|
---|
| 793 | </listitem>
|
---|
| 794 | </varlistentry>
|
---|
| 795 |
|
---|
| 796 | <varlistentry id="libldap_r">
|
---|
[d6da5da] | 797 | <term><filename class="libraryfile">libldap_r.so</filename></term>
|
---|
[814e53c] | 798 | <listitem>
|
---|
[b5e36dd] | 799 | <para>
|
---|
| 800 | contains the functions required by the LDAP programs to
|
---|
| 801 | produce the results from LDAP requests.
|
---|
| 802 | </para>
|
---|
[814e53c] | 803 | <indexterm zone="openldap libldap_r">
|
---|
[c00932a] | 804 | <primary sortas="c-libldap_r">libldap_r.so</primary>
|
---|
[814e53c] | 805 | </indexterm>
|
---|
| 806 | </listitem>
|
---|
| 807 | </varlistentry>
|
---|
| 808 |
|
---|
| 809 | </variablelist>
|
---|
| 810 |
|
---|
| 811 | </sect2>
|
---|
[9905a3c] | 812 |
|
---|
| 813 | </sect1>
|
---|