[K12OSN] Running ldap as root or ldap

John Hegarty jh at clongowes.net
Tue Aug 23 19:09:58 UTC 2005


os = k12ltsp 4.4

I'm having a problem with ldap/samba where slapd is stopping at night.
if I run "service ldap start" or "service ldap restart" it claims to
have started but is in fact stopped. 

If I reboot the computer it will hang trying to start slapd. When this
first happened I ran linux rescue and ran slapd_db_recover as I thought
the database might be corrupted. It ran fine and the computer rebooted
though slapd was stopped when I logged in.

If I run slapd, when logged in as root, it starts no problem and will be
fine all day.

I turned on logging to see if anything showed up and I got the following
which seems to suggest that it is a permissions thing. This is the
output when "service ldap start" or "service ldap restart" is used.

Aug 23 19:46:31 server-01 slapd[22388]: bdb_back_initialize: Sleepycat
Software: Berkeley DB 4.3.27: (December 22, 2004) 
Aug 23 19:46:31 server-01 slapd[22388]: bdb_db_init: Initializing BDB
database 
Aug 23 19:46:31 server-01 slapd[22389]: bdb_db_open: dbenv_open failed:
Permission denied (13) 
Aug 23 19:46:31 server-01 slapd[22389]: backend_startup: bi_db_open
failed! (13) 
Aug 23 19:46:31 server-01 slapd[22389]: bdb(dc=cwc,dc=edu):
DB_ENV->lock_id_free interface requires an environment configured for
the locking subsystem 

The owner and group on the __db.00* files are both root. The owner and
group on the other files in /var/lib/ldap are ldap.

I googled around and found suggestions that the problem might be who is
running the service root or ldap. I presume that running the service as
root is not desirable but I'm not sure where to go from here. I'm also
wondering why it is stopping at night. I hoping the logs might shed some
light on this tomorrow.

Anyone got any suggestions?

Thanks

jh




More information about the K12OSN mailing list