Red Hat Bugzilla – Bug 186984
Slapd doesnt start after FC4 -> FC5
Last modified: 2007-11-30 17:11:28 EST
Description of problem:
After the upgrade from FC-4 to FC-5 slapd doesnt starts.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Upgrade from FC-4 to FC-5
2. Update your /var/lib/ldap/ db files
3. Add DB_CONFIG and all needed tuning
4. Run service ldap start
[root@mr ldap]# service ldap start
Checking configuration files for slapd: unable to open file
"/var/run/slapd.pid": 13 (Permission denied)
Service should be started.
This looks like init script problem
As a temporary solution touch empty /var/run/slapd.pid
and chown it to ldap user before start of service.
Created attachment 127976 [details]
ldap init script patch
Same here with all FC5 machines, while FC4 machines work perfectly! The problem
seems to be that the ldap user may not write the pid to /var/run/slapd.pid
(because the /var/run dir is owned by root with chmod 755).
The problem rises in the configtest function that is called by start on line 124:
if ! action $"Checking configuration files for $prog: " /sbin/runuser -m -s
"$slaptest" -- "$user" "$slaptestflags"; then
When I replace line number 124 of /etc/init.d/ldap by this (as in FC4):
if ! action $"Checking configuration files for $prog: " $slaptest
then it goes on and tells me that ldap starts succesfully, but in fact it does
not. However when I run '$ slapd' from the shell the in does start and works
just fine, I assume because I run it as root.
This bug is also present in openldap-servers-2.3.27-2 from Rawhide. Will this
be fixed before FC6?
In rawhide, the /etc/openldap/slapd.conf file puts the pid and args files in
the new /var/run/openldap/ directory, which is 755 mode and owned by the ldap
user. If you are using an older slapd.conf file, you will need to manually
merge the changes from /etc/openldap/slapd.conf.rpmnew into your slapd.conf
Jay, I may have spoke too soon. See
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=204593#c3. It appears that
I jumped on the wrong bug. Bug #204593 seems to match better and, luckily, I
found a solution to that one.
@Jay: Thanks that works for me! :)
openldap-2.3.30-2.fc5 has been pushed for fc5, which should resolve this issue. If these problems are still present in this version, then please make note of it in this bug report.