source: server/other/openldap.xml@ 9a6f6511

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 9a6f6511 was 9a6f6511, checked in by Randy McMurchy <randy@…>, 19 years ago

Updated to OpenLDAP-2.2.26 stable release

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@4918 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 19.0 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY openldap-download-http "http://gd.tuwien.ac.at/infosys/network/OpenLDAP/openldap-stable/openldap-&openldap-download-version;.tgz">
8 <!ENTITY openldap-download-ftp "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-stable/openldap-&openldap-download-version;.tgz">
9 <!ENTITY openldap-md5sum "afc8700b5738da863b30208e1d3e9de8">
10 <!ENTITY openldap-size "2.6 MB">
11 <!ENTITY openldap-buildsize "86 MB">
12 <!ENTITY openldap-time "1.5 SBU with an additional 15 minutes to run the tests (processor independent)">
13]>
14
15<sect1 id="openldap" xreflabel="OpenLDAP-&openldap-version;">
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
32 <para>The <application>OpenLDAP</application> package provides an open
33 source implementation of the Lightweight Directory Access Protocol.</para>
34
35 <bridgehead renderas="sect3">Package Information</bridgehead>
36 <itemizedlist spacing="compact">
37 <listitem>
38 <para>Download (HTTP): <ulink url="&openldap-download-http;"/></para>
39 </listitem>
40 <listitem>
41 <para>Download (FTP): <ulink url="&openldap-download-ftp;"/></para>
42 </listitem>
43 <listitem>
44 <para>Download MD5 sum: &openldap-md5sum;</para>
45 </listitem>
46 <listitem>
47 <para>Download size: &openldap-size;</para>
48 </listitem>
49 <listitem>
50 <para>Estimated disk space required: &openldap-buildsize;</para>
51 </listitem>
52 <listitem>
53 <para>Estimated build time: &openldap-time;</para>
54 </listitem>
55 </itemizedlist>
56
57 <note>
58 <para>The <application>OpenLDAP</application> stable releases are
59 packaged without version numbers in the tarball names. You can see the
60 relationship between the version number and name of the tarball at <ulink
61 url="http://www.openldap.org/software/download/"/>.</para>
62 </note>
63
64 <bridgehead renderas="sect3">OpenLDAP Dependencies</bridgehead>
65
66 <bridgehead renderas="sect4">Required</bridgehead>
67 <para><xref linkend="db"/> (recommended) or
68 <xref linkend="gdbm"/></para>
69
70 <bridgehead renderas="sect4">Recommended</bridgehead>
71 <para><xref linkend="cyrus-sasl"/> and <xref linkend="openssl"/></para>
72
73 <bridgehead renderas="sect4">Optional</bridgehead>
74 <para><xref linkend="tcpwrappers"/>,
75 <ulink url="http://www.gnu.org/software/pth/">GNU Pth</ulink>,
76 <ulink url="http://www.openslp.org/">OpenSLP</ulink> and
77 <ulink url="http://www.unixodbc.org/">unixODBC</ulink></para>
78
79 </sect2>
80
81 <sect2 role="installation">
82 <title>Installation of OpenLDAP</title>
83
84 <para>Install <application>OpenLDAP</application> by
85 running the following commands:</para>
86
87<screen><userinput>./configure --prefix=/usr --libexecdir=/usr/sbin \
88 --sysconfdir=/etc --localstatedir=/srv/ldap \
89 --enable-ldbm --disable-debug &amp;&amp;
90make depend &amp;&amp;
91make &amp;&amp;
92make test</userinput></screen>
93
94 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
95
96<screen role="root"><userinput>make install &amp;&amp;
97chmod 755 /usr/lib/libl*-2.2.so.7.0.19 &amp;&amp;
98install -v -m755 -d /usr/share/doc/openldap-&openldap-version;/{drafts,rfc} &amp;&amp;
99install -v -m644 doc/drafts/* \
100 /usr/share/doc/openldap-&openldap-version;/drafts &amp;&amp;
101install -v -m644 doc/rfc/* \
102 /usr/share/doc/openldap-&openldap-version;/rfc</userinput></screen>
103
104 </sect2>
105
106 <sect2 role="commands">
107 <title>Command Explanations</title>
108
109 <para><parameter>--libexecdir=/usr/sbin</parameter>: Installs the server
110 executables in <filename class="directory">/usr/sbin</filename> instead of
111 <filename class="directory">/usr/libexec</filename>.</para>
112
113 <para><parameter>--sysconfdir=/etc</parameter>: Sets the configuration file
114 directory to avoid the default of
115 <filename class="directory">/usr/etc</filename>.</para>
116
117 <para><parameter>--localstatedir=/srv/ldap</parameter>: Sets the directory
118 to use for the LDAP directory database, replication logs and
119 run-time variable data.</para>
120
121 <para><parameter>--enable-ldbm</parameter>: Build <command>slapd</command>
122 with the primary database back end using either
123 <application>Berkeley DB</application> or
124 <application>GNU Database Manager</application>.</para>
125
126 <para><parameter>--disable-debug</parameter>: Disable debugging code.</para>
127
128 <para><command>make test</command>: Validates the correct build of the
129 package. If you've enabled <application>tcp_wrappers</application>, ensure you
130 add 127.0.0.1 to the <parameter>slapd</parameter> line in the
131 <filename>/etc/hosts.allow</filename> file if you have a
132 restrictive <filename>/etc/hosts.deny</filename> file. If you logged the
133 output of the <command>make test</command>, an easy test to see if all the
134 tests succeeded is to issue <command>grep ">>>>> Test succeeded"
135 <replaceable>[logfilename]</replaceable> | wc -l</command>. You should have
136 <computeroutput>39</computeroutput> returned.</para>
137
138 <para><command>chmod 755 /usr/lib/libl*-2.2.so.7.0.17</command>: This command
139 adds the executable bit to the shared libraries.</para>
140
141 <para><option>--disable-bdb --disable-hdb --with-ldbm-api=gdbm</option>:
142 Use these parameters to the <command>configure</command> command if you
143 wish to use GDBM instead of Berkeley DB as the primary backend
144 database.</para>
145 </sect2>
146
147 <sect2 role="configuration">
148 <title>Configuring OpenLDAP</title>
149
150 <sect3 id="openldap-config">
151 <title>Config Files</title>
152
153 <para><filename>/etc/openldap/*</filename></para>
154
155 <indexterm zone="openldap openldap-config">
156 <primary sortas="e-etc-openldap">/etc/openldap/*</primary>
157 </indexterm>
158
159 </sect3>
160
161 <sect3>
162 <title>Configuration Information</title>
163
164 <para>Configuring the <command>slapd</command> and
165 <command>slurpd</command> servers can be complex. Securing the LDAP
166 directory, especially if you are storing non-public data such as
167 password databases, can also be a challenging task. You'll need to
168 modify the <filename>/etc/openldap/slapd.conf</filename> and
169 <filename>/etc/openldap/ldap.conf</filename> files to set up
170 <application>OpenLDAP</application> for your particular needs.</para>
171
172 <indexterm zone="openldap openldap-config">
173 <primary
174 sortas="e-etc-openldap-slapd.conf">/etc/openldap/slapd.conf</primary>
175 </indexterm>
176
177 <indexterm zone="openldap openldap-config">
178 <primary
179 sortas="e-etc-openldap-ldap.conf">/etc/openldap/ldap.conf</primary>
180 </indexterm>
181
182 <para>Resources to assist you with topics such as choosing a directory
183 configuration, backend and database definitions, access control settings,
184 running as a user other than <systemitem class="username">root</systemitem>
185 and setting a <command>chroot</command> environment include:</para>
186
187 <itemizedlist spacing='compact'>
188 <listitem>
189 <para>The <command>slapd</command> man page</para>
190 </listitem>
191 <listitem>
192 <para>The <filename>slapd.conf</filename> man page</para>
193 </listitem>
194 <listitem>
195 <para>The <ulink
196 url="http://www.openldap.org/doc/admin22/">OpenLDAP 2.2 Administrator's
197 Guide</ulink></para>
198 </listitem>
199 <listitem>
200 <para>Documents located at
201 <ulink url="http://www.openldap.org/pub/"/></para>
202 </listitem>
203 </itemizedlist>
204
205 </sect3>
206
207 <sect3>
208 <title>Utilizing GDBM</title>
209
210 <para>To utilize <application>GDBM</application> as the database
211 backend, the <quote>database</quote> entry in
212 <filename>/etc/openldap/slapd.conf</filename> must be changed from
213 <quote>bdb</quote> to <quote>ldbm</quote>. You can use both by
214 creating an additional database section in
215 <filename>/etc/openldap/slapd.conf</filename>.</para>
216
217 </sect3>
218
219 <sect3>
220 <title>Mozilla Address Directory</title>
221
222 <para>By default, LDAPv2 support is disabled in the
223 <filename>slapd.conf</filename> file. Once the database is properly
224 set up and <application>Mozilla</application> is configured to use the
225 directory, you must add <option>allow bind_v2</option> to the
226 <filename>slapd.conf</filename> file.</para>
227
228 </sect3>
229
230 <sect3 id="openldap-init">
231 <title>Boot Script</title>
232
233 <para>To automate the startup of the LDAP server at system bootup,
234 install the <filename>/etc/rc.d/init.d/openldap</filename> init script
235 included in the <xref linkend="intro-important-bootscripts"/> package
236 using the following command:</para>
237
238 <indexterm zone="openldap openldap-init">
239 <primary sortas="f-openldap">openldap</primary>
240 </indexterm>
241
242<screen role="root"><userinput>make install-openldap1</userinput></screen>
243
244 <para><emphasis>Note:</emphasis> The init script you just installed only
245 starts the <command>slapd</command> daemon. If you wish to also start the
246 <command>slurpd</command> daemon at system startup, install a modified
247 version of the script using this command:</para>
248
249<screen role="root"><userinput>make install-openldap2</userinput></screen>
250
251 <note>
252 <para>The init script starts the daemons without any parameters.
253 You'll need to modify the script to include the parameters needed for
254 your specific configuration. See the <command>slapd</command> and
255 <command>slurpd</command> man pages for parameter information.</para>
256 </note>
257
258 </sect3>
259
260 <sect3>
261 <title>Testing the Configuration</title>
262
263 <para>Start the LDAP server using the init script:</para>
264
265<screen role="root"><userinput>/etc/rc.d/init.d/openldap start</userinput></screen>
266
267 <para>Verify access to the LDAP server with the following
268 command:</para>
269
270<screen><userinput>ldapsearch -x -b '' -s base '(objectclass=*)' namingContexts</userinput></screen>
271
272 <para>The expected result is:</para>
273
274<screen><computeroutput># extended LDIF
275#
276# LDAPv3
277# base &lt;&gt; with scope base
278# filter: (objectclass=*)
279# requesting: namingContexts
280#
281
282#
283dn:
284namingContexts: dc=my-domain,dc=com
285
286# search result
287search: 2
288result: 0 Success
289
290# numResponses: 2
291# numEntries: 1</computeroutput></screen>
292
293 </sect3>
294
295 </sect2>
296
297 <sect2 role="content">
298 <title>Contents</title>
299
300 <segmentedlist>
301 <segtitle>Installed Programs</segtitle>
302 <segtitle>Installed Libraries</segtitle>
303 <segtitle>Installed Directories</segtitle>
304
305 <seglistitem>
306 <seg>ldapadd, ldapcompare, ldapdelete, ldapmodify, ldapmodrdn,
307 ldappasswd, ldapsearch, ldapwhoami, slapadd, slapcat, slapd, slapdn,
308 slapindex, slappasswd, slaptest, and slurpd</seg>
309 <seg>liblber.[so,a], libldap.[so,a], and libldap_r.[so,a]</seg>
310 <seg>/etc/openldap, /srv/ldap, and /usr/share/openldap</seg>
311 </seglistitem>
312 </segmentedlist>
313
314 <variablelist>
315 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
316 <?dbfo list-presentation="list"?>
317 <?dbhtml list-presentation="table"?>
318
319 <varlistentry id="ldapadd">
320 <term><command>ldapadd</command></term>
321 <listitem>
322 <para>opens a connection to an LDAP server, binds and adds
323 entries.</para>
324 <indexterm zone="openldap ldapadd">
325 <primary sortas="b-ldapadd">ldapadd</primary>
326 </indexterm>
327 </listitem>
328 </varlistentry>
329
330 <varlistentry id="ldapcompare">
331 <term><command>ldapcompare</command></term>
332 <listitem>
333 <para>opens a connection to an LDAP server, binds and performs
334 a compare using specified parameters.</para>
335 <indexterm zone="openldap ldapcompare">
336 <primary sortas="b-ldapcompare">ldapcompare</primary>
337 </indexterm>
338 </listitem>
339 </varlistentry>
340
341 <varlistentry id="ldapdelete">
342 <term><command>ldapdelete</command></term>
343 <listitem>
344 <para> opens a connection to an LDAP server, binds and deletes
345 one or more entries.</para>
346 <indexterm zone="openldap ldapdelete">
347 <primary sortas="b-ldapdelete">ldapdelete</primary>
348 </indexterm>
349 </listitem>
350 </varlistentry>
351
352 <varlistentry id="ldapmodify">
353 <term><command>ldapmodify</command></term>
354 <listitem>
355 <para>opens a connection to an LDAP server, binds and modifies
356 entries.</para>
357 <indexterm zone="openldap ldapmodify">
358 <primary sortas="b-ldapmodify">ldapmodify</primary>
359 </indexterm>
360 </listitem>
361 </varlistentry>
362
363 <varlistentry id="ldapmodrdn">
364 <term><command>ldapmodrdn</command></term>
365 <listitem>
366 <para>opens a connection to an LDAP server, binds and modifies
367 the RDN of entries.</para>
368 <indexterm zone="openldap ldapmodrdn">
369 <primary sortas="b-ldapmodrdn">ldapmodrdn</primary>
370 </indexterm>
371 </listitem>
372 </varlistentry>
373
374 <varlistentry id="ldappasswd">
375 <term><command>ldappasswd</command></term>
376 <listitem>
377 <para>is a tool to set the password of an LDAP user.</para>
378 <indexterm zone="openldap ldappasswd">
379 <primary sortas="b-ldappasswd">ldappasswd</primary>
380 </indexterm>
381 </listitem>
382 </varlistentry>
383
384 <varlistentry id="ldapsearch">
385 <term><command>ldapsearch</command></term>
386 <listitem>
387 <para>opens a connection to an LDAP server, binds and performs
388 a search using specified parameters.</para>
389 <indexterm zone="openldap ldapsearch">
390 <primary sortas="b-ldapsearch">ldapsearch</primary>
391 </indexterm>
392 </listitem>
393 </varlistentry>
394
395 <varlistentry id="ldapwhoami">
396 <term><command>ldapwhoami</command></term>
397 <listitem>
398 <para>opens a connection to an LDAP server, binds and displays
399 whoami information.</para>
400 <indexterm zone="openldap ldapwhoami">
401 <primary sortas="b-ldapwhoami">ldapwhoami</primary>
402 </indexterm>
403 </listitem>
404 </varlistentry>
405
406 <varlistentry id="slapadd">
407 <term><command>slapadd</command></term>
408 <listitem>
409 <para>is used to add entries specified in LDAP Directory Interchange
410 Format (LDIF) to an LDAP database.</para>
411 <indexterm zone="openldap slapadd">
412 <primary sortas="b-slapadd">slapadd</primary>
413 </indexterm>
414 </listitem>
415 </varlistentry>
416
417 <varlistentry id="slapcat">
418 <term><command>slapcat</command></term>
419 <listitem>
420 <para>is used to generate an LDAP LDIF output based upon the
421 contents of a slapd database.</para>
422 <indexterm zone="openldap slapcat">
423 <primary sortas="b-slapcat">slapcat</primary>
424 </indexterm>
425 </listitem>
426 </varlistentry>
427
428 <varlistentry id="slapd">
429 <term><command>slapd</command></term>
430 <listitem>
431 <para>is the stand-alone LDAP server.</para>
432 <indexterm zone="openldap slapd">
433 <primary sortas="b-slapd">slapd</primary>
434 </indexterm>
435 </listitem>
436 </varlistentry>
437
438 <varlistentry id="slapdn">
439 <term><command>slapdn</command></term>
440 <listitem>
441 <para>checks a list of string-represented DNs based on schema
442 syntax.</para>
443 <indexterm zone="openldap slapdn">
444 <primary sortas="b-slapdn">slapdn</primary>
445 </indexterm>
446 </listitem>
447 </varlistentry>
448
449 <varlistentry id="slapindex">
450 <term><command>slapindex</command></term>
451 <listitem>
452 <para>is used to regenerate slapd indices based upon the current
453 contents of a database.</para>
454 <indexterm zone="openldap slapindex">
455 <primary sortas="b-slapindex">slapindex</primary>
456 </indexterm>
457 </listitem>
458 </varlistentry>
459
460 <varlistentry id="slappasswd">
461 <term><command>slappasswd</command></term>
462 <listitem>
463 <para>is an <application>OpenLDAP</application> password
464 utility.</para>
465 <indexterm zone="openldap slappasswd">
466 <primary sortas="b-slappasswd">slappasswd</primary>
467 </indexterm>
468 </listitem>
469 </varlistentry>
470
471 <varlistentry id="slaptest">
472 <term><command>slaptest</command></term>
473 <listitem>
474 <para>checks the sanity of the <filename>slapd.conf</filename>
475 file.</para>
476 <indexterm zone="openldap slaptest">
477 <primary sortas="b-slaptest">slaptest</primary>
478 </indexterm>
479 </listitem>
480 </varlistentry>
481
482 <varlistentry id="slurpd">
483 <term><command>slurpd</command></term>
484 <listitem>
485 <para>is the stand-alone LDAP replication server.</para>
486 <indexterm zone="openldap slurpd">
487 <primary sortas="b-slurpd">slurpd</primary>
488 </indexterm>
489 </listitem>
490 </varlistentry>
491
492 <varlistentry id="liblber">
493 <term><filename class='libraryfile'>liblber.[so,a]</filename></term>
494 <listitem>
495 <para>is a set of lightweight Basic Encoding Rules routines. These
496 routines are used by the LDAP library routines to encode and decode
497 LDAP protocol elements using the (slightly simplified) Basic
498 Encoding Rules defined by LDAP. They are not normally used directly
499 by an LDAP application program except in the handling of controls
500 and extended operations.</para>
501 <indexterm zone="openldap liblber">
502 <primary sortas="c-liblber">liblber.[so,a]</primary>
503 </indexterm>
504 </listitem>
505 </varlistentry>
506
507 <varlistentry id="libldap">
508 <term><filename class='libraryfile'>libldap.[so,a]</filename></term>
509 <listitem>
510 <para>supports the LDAP programs and provide functionality for
511 other programs interacting with LDAP.</para>
512 <indexterm zone="openldap libldap">
513 <primary sortas="c-libldap">libldap.[so,a]</primary>
514 </indexterm>
515 </listitem>
516 </varlistentry>
517
518 <varlistentry id="libldap_r">
519 <term><filename class='libraryfile'>libldap_r.[so,a]</filename></term>
520 <listitem>
521 <para>contains the functions required by the LDAP programs to
522 produce the results from LDAP requests.</para>
523 <indexterm zone="openldap libldap_r">
524 <primary sortas="c-libldap_r">libldap_r.[so,a]</primary>
525 </indexterm>
526 </listitem>
527 </varlistentry>
528
529 </variablelist>
530
531 </sect2>
532
533</sect1>
Note: See TracBrowser for help on using the repository browser.