Bug 141890 - [patch] slapd(8): The slapd server starts/restarts way too long - chicken and egg problem
Summary: [patch] slapd(8): The slapd server starts/restarts way too long - chicken and...
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: 8.0-RELEASE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-22 11:40 UTC by Filip Palian
Modified: 2018-01-03 05:16 UTC (History)
0 users

See Also:


Attachments
file.diff (432 bytes, patch)
2009-12-22 11:40 UTC, Filip Palian
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Filip Palian 2009-12-22 11:40:08 UTC
The slapd server (and other services) on system boot or on restart takes
ages to run, because it waits to query itself. This situation takes place
when the system uses pam_ldap, nss_ldap and when nsswitch.conf is
configured to query LDAP database.

Fix: Dirty fix for this problem is to apply the attached patch on
"/usr/local/etc/rc.d/slapd". To make this work you also need to create
"nsswitch.conf.ldap" and "nsswitch.conf.noldap" in "/etc" directory
with the following content:

nsswitch.conf.ldap:
 group: files ldap
 group_compat: nis
 hosts:	files dns
 networks: files
 passwd: files ldap
 passwd_compat: nis
 shells: files
 services: compat
 services_compat: nis
 protocols: files
 rpc: files

nsswitch.conf.noldap:
 group: files
 group_compat: nis
 hosts:	files dns
 networks: files
 passwd: files
 passwd_compat: nis
 shells: files
 services: compat
 services_compat: nis
 protocols: files
 rpc: files


Credits goes to Eric Masson (http://markmail.org/message/ecc6orwz43bkk5ib).

Patch attached with submission follows:
How-To-Repeat: 1) install and configure OpenLDAP server, pam_ldap and nss_ldap
2) reboot your system
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:00:54 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped