Hi everyone,
i just installed a fresh copy of Zentyal 2.0.16 on Ubuntu Server 11.04 (Natty) from the official Ubuntu repositories.
Unfortunately, Natty is a must-have due to some dependency issues related to kernel encryption-features.
Zentyal itself is working fine, except for one thing:
When i reboot the machine, it seems that slapd does not get shut down correctly, therefore the LDAP DB goes corrupt, _every_ reboot.
Luckily this installation is not productive yet, so I can rebuild the DB using db4.8_recovery, slapcat and slapadd.
Does anyone else experience this on Natty (I assume this is specific to Natty since I couldn't reproduce this on Lucid 10.04)?
Regards from Germany,
Markus
EDIT:
slapd error message look like this
May 19 22:27:42 ux01 slapd[1918]: @(#) $OpenLDAP: slapd 2.4.23 (Apr 7 2011 18:00:55) $#012#011buildd@allspice:/build/buildd/openldap-2.4.23/debian/build/servers/slapd
May 19 22:27:42 ux01 slapd[1919]: hdb_db_open: database "dc=ux01,dc=home,dc=local": unclean shutdown detected; attempting recovery.
May 19 22:27:42 ux01 slapd[1919]: hdb_db_open: database "dc=home,dc=local": unclean shutdown detected; attempting recovery.
May 19 22:27:42 ux01 slapd[1919]: slapd starting
May 19 22:27:42 ux01 slapd[1919]: bdb(dc=ux01,dc=home,dc=local): PANIC: fatal region error detected; run recovery
It even seems that a simple "service slapd restart" or "/etc/init.d/slapd restart" kills the DB.
Here's my log after "service slapd stop":
May 20 12:47:45 ux01 slapd[6213]: daemon: shutdown requested and initiated.
May 20 12:47:45 ux01 slapd[6213]: slapd shutdown: waiting for 0 operations/tasks to finish
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): PANIC: fatal region error detected; run recovery
May 20 12:47:45 ux01 slapd[6213]: last message repeated 12 times
May 20 12:47:45 ux01 slapd[6213]: bdb_db_close: database "dc=ux01,dc=home,dc=local": txn_checkpoint failed: DB_RUNRECOVERY: Fatal error, run database recovery (-30974).
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): File handles still open at environment close
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/id2entry.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/dn2id.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/objectClass.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/log.0000000001
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/entryUUID.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/entryCSN.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/cn.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/gidNumber.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): Open file handle: /var/lib/ldap/memberUid.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=ux01,dc=home,dc=local): PANIC: fatal region error detected; run recovery
May 20 12:47:45 ux01 slapd[6213]: bdb_db_close: database "dc=ux01,dc=home,dc=local": close failed: DB_RUNRECOVERY: Fatal error, run database recovery (-30974)
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=home,dc=local): PANIC: fatal region error detected; run recovery
May 20 12:47:45 ux01 slapd[6213]: last message repeated 3 times
May 20 12:47:45 ux01 slapd[6213]: bdb_db_close: database "dc=home,dc=local": txn_checkpoint failed: DB_RUNRECOVERY: Fatal error, run database recovery (-30974).
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=home,dc=local): File handles still open at environment close
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=home,dc=local): Open file handle: /var/lib/ldap/id2entry.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=home,dc=local): Open file handle: /var/lib/ldap/dn2id.bdb
May 20 12:47:45 ux01 slapd[6213]: bdb(dc=home,dc=local): PANIC: fatal region error detected; run recovery
May 20 12:47:45 ux01 slapd[6213]: bdb_db_close: database "dc=home,dc=local": close failed: DB_RUNRECOVERY: Fatal error, run database recovery (-30974)
May 20 12:47:45 ux01 slapd[6213]: slapd stopped.
So why are there still file handles open, this can't be good?
Furthermore, after a recovery of the LDAP database, slapd runs as long as Zentyal doesn't try to query something. As soon as I try to do something to Users and Groups, slapd panics and quits.