1SLAPD(8C)                                                            SLAPD(8C)
2
3
4

NAME

6       slapd - Stand-alone LDAP Daemon
7

SYNOPSIS

9       /usr/lib64/slapd  [-[4|6]] [-T {acl|add|auth|cat|dn|index|passwd|test}]
10       [-d debug-level] [-f slapd-config-file] [-F slapd-config-directory] [-h
11       URLs]  [-n  service-name]  [-s syslog-level] [-l syslog-local-user] [-r
12       directory] [-u user] [-g group] [-c cookie]
13

DESCRIPTION

15       Slapd is the stand-alone LDAP daemon. It listens for  LDAP  connections
16       on any number of ports (default 389), responding to the LDAP operations
17       it receives over these connections.  slapd is typically invoked at boot
18       time, usually out of /etc/rc.local.  Upon startup, slapd normally forks
19       and disassociates itself from the invoking tty.  If configured  in  the
20       config  file  (or  config  directory), the slapd process will print its
21       process ID (see getpid(2)) to a .pid file, as well as the command  line
22       options during invocation to an .args file (see slapd.conf(5)).  If the
23       -d flag is given, even with a zero argument, slapd will  not  fork  and
24       disassociate from the invoking tty.
25
26       Slapd  can  be  configured to provide replicated service for a database
27       with the help of slurpd, the standalone LDAP update replication daemon.
28       See slurpd(8) for details.
29
30       See the "OpenLDAP Administrator's Guide" for more details on slapd.
31

OPTIONS

33       -4     Listen on IPv4 addresses only.
34
35       -6     Listen on IPv6 addresses only.
36
37       -T {a|c|d|i|p|t|acl|auth}
38              Run in Tool mode. The additional argument selects whether to run
39              as slapadd, slapcat, slapdn, slapindex, slappasswd, or  slaptest
40              (slapacl  and  slapauth  need the entire "acl" and "auth" option
41              value to be spelled out, as "a" is reserved to  slapadd).   This
42              option should be the first option specified when it is used; any
43              remaining options will be interpreted by the corresponding  slap
44              tool  program, according to the respective man pages.  Note that
45              these tool programs will usually be  symbolic  links  to  slapd.
46              This  option is provided for situations where symbolic links are
47              not provided or not usable.
48
49       -d debug-level
50              Turn on debugging as defined by debug-level.  If this option  is
51              specified,  even  with  a  zero argument, slapd will not fork or
52              disassociate from the invoking terminal.  Some general operation
53              and  status  messages  are printed for any value of debug-level.
54              debug-level is taken as a bit string, with each bit  correspond‐
55              ing   to   a  different  kind  of  debugging  information.   See
56              <ldap_log.h> for details.  Remember that if you turn  on  packet
57              logging, packets containing bind passwords will be output, so if
58              you redirect the log to a logfile, that file should be read-pro‐
59              tected.
60
61       -s syslog-level
62              This  option  tells  slapd  at  what  level debugging statements
63              should be logged to the syslog(8) facility.
64
65       -n service-name
66              Specifies the service  name  for  logging  and  other  purposes.
67              Defaults to basename of argv[0], i.e.: "slapd".
68
69       -l syslog-local-user
70              Selects  the  local user of the syslog(8) facility. Value can be
71              LOCAL0, through LOCAL7, as well as USER and DAEMON.  The default
72              is  LOCAL4.   However,  this option is only permitted on systems
73              that support local users with the syslog(8) facility.
74
75       -f slapd-config-file
76              Specifies  the  slapd  configuration  file.   The   default   is
77              /etc/openldap/slapd.conf.
78
79       -F slapd-config-directory
80              Specifies  the  slapd  configuration  directory.  The default is
81              /etc/openldap/slapd.d.  If both -f and  -F  are  specified,  the
82              config  file will be read and converted to config directory for‐
83              mat and written to the specified directory.  If  neither  option
84              is  specified,  slapd  will  attempt  to read the default config
85              directory before trying to use the default  config  file.  If  a
86              valid  config  directory  exists then the default config file is
87              ignored. All of the slap  tools  that  use  the  config  options
88              observe this same behavior.
89
90       -h URLlist
91              slapd  will  by  default  serve  ldap:///  (LDAP over TCP on all
92              interfaces on default LDAP port).  That is, it will  bind  using
93              INADDR_ANY  and  port 389.  The -h option may be used to specify
94              LDAP (and other scheme) URLs to serve.  For example, if slapd is
95              given  -h  "ldap://127.0.0.1:9009/ ldaps:/// ldapi:///", it will
96              listen on 127.0.0.1:9009 for LDAP,  0.0.0.0:636  for  LDAP  over
97              TLS, and LDAP over IPC (Unix domain sockets).  Host 0.0.0.0 rep‐
98              resents INADDR_ANY (any interface).  A space separated  list  of
99              URLs  is  expected.   The  URLs should be of the LDAP, LDAPS, or
100              LDAPI schemes, and generally without  a  DN  or  other  optional
101              parameters (excepting as discussed below).  Support for the lat‐
102              ter two  schemes  depends  on  selected  configuration  options.
103              Hosts may be specified by name or IPv4 and IPv6 address formats.
104              Ports, if specified, must be numeric.  The default ldap://  port
105              is 389 and the default ldaps:// port is 636.
106
107              The  listener  permissions  are indicated by "x-mod=-rwxrwxrwx",
108              "x-mod=0777" or "x-mod=777", where any of the "rwx" can  be  "-"
109              to  suppress the related permission, while any of the "7" can be
110              any legal octal digit, according to chmod(1).  The listeners can
111              take  advantage  of the "x-mod" extension to apply rough limita‐
112              tions to operations, e.g.  allow  read  operations  ("r",  which
113              applies  to  search  and  compare), write operations ("w", which
114              applies to add, delete, modify and modrdn), and  execute  opera‐
115              tions  ("x",  which means bind is required).  "User" permissions
116              apply to authenticated users, while "other" apply  to  anonymous
117              users;   "group"   permissions   are   ignored.    For  example,
118              "ldap:///????x-mod=-rw-------" means that read and write is only
119              allowed  for authenticated connections, and bind is required for
120              all operations.  This feature is experimental, and  requires  to
121              be manually enabled at configure time.
122
123       -r directory
124              Specifies  a directory to become the root directory.  slapd will
125              change the current working directory to this directory and  then
126              chroot(2) to this directory.  This is done after opening listen‐
127              ers but before reading any configuration  file  or  initializing
128              any  backend.   When  used as a security mechanism, it should be
129              used in conjunction with -u and -g options.
130
131       -u user
132              slapd will run slapd with the specified user  name  or  id,  and
133              that  user's  supplementary  group access list as set with init‐
134              groups(3).  The group ID is also changed  to  this  user's  gid,
135              unless  the  -g option is used to override.  Note when used with
136              -r, slapd will use the user database in the change root environ‐
137              ment.
138
139              Note that on some systems, running as a non-privileged user will
140              prevent passwd back-ends from accessing the encrypted passwords.
141              Note  also  that  any  shell back-ends will run as the specified
142              non-privileged user.
143
144       -g group
145              slapd will run with the specified group name or id.   Note  when
146              used  with  -r,  slapd will use the group database in the change
147              root environment.
148
149       -c cookie
150              This option provides a cookie for the syncrepl replication  con‐
151              sumer.   The  cookie  is  a  comma  separated list of name=value
152              pairs.  Currently supported syncrepl cookie fields are  rid  and
153              csn.   rid  identifies  a replication thread within the consumer
154              server and  is  used  to  find  the  syncrepl  specification  in
155              slapd.conf(5)  having the matching replication identifier in its
156              definition. The rid must be provided  in  order  for  any  other
157              specified  values to be used.  csn is the commit sequence number
158              received by a previous synchronization and represents the  state
159              of  the  consumer replica content which the syncrepl engine will
160              synchronize to the current provider content.
161

EXAMPLES

163       To start slapd and have it fork and detach from the terminal and  start
164       serving  the  LDAP  databases  defined in the default config file, just
165       type:
166
167            /usr/lib64/slapd
168
169       To start slapd with an alternate configuration file, and turn on  volu‐
170       minous debugging which will be printed on standard error, type:
171
172            /usr/lib64/slapd -f /var/tmp/slapd.conf -d 255
173
174       To test whether the configuration file is correct or not, type:
175
176            /usr/lib64/slapd -Tt
177

SEE ALSO

179       ldap(3),  slapd.conf(5),  slapd.access(5), slapacl(8), slapadd(8), sla‐
180       pauth(8),   slapcat(8),   slapdn(8),    slapindex(8),    slappasswd(8),
181       slaptest(8), slurpd(8)
182
183       "OpenLDAP Administrator's Guide" (http://www.OpenLDAP.org/doc/admin/)
184

BUGS

186       See http://www.openldap.org/its/
187

ACKNOWLEDGEMENTS

189       OpenLDAP   is   developed   and  maintained  by  The  OpenLDAP  Project
190       (http://www.openldap.org/).  OpenLDAP is  derived  from  University  of
191       Michigan LDAP 3.3 Release.
192
193
194
195OpenLDAP 2.3.34                    2007/2/16                         SLAPD(8C)
Impressum