Bug 192861

Summary: Database crash everytime unclean shutdown occured
Product: Red Hat Enterprise Linux 4 Reporter: Somsak Sriprayoonsakul <ssy>
Component: openldapAssignee: Jan Safranek <jsafrane>
Status: CLOSED ERRATA QA Contact: Jay Turner <jturner>
Severity: high Docs Contact:
Priority: medium    
Version: 4.0CC: jplans, srevivo
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHBA-2007-0739 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-15 16:04:03 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Somsak Sriprayoonsakul 2006-05-23 17:19:36 UTC
Description of problem:

When an unclean shutdown occured, openldap database always crash due to
incomplete database commit. This make openldap can not start at boot time
(failed to lock database) or openldap can start but query get stuck.

Version-Release number of selected component (if applicable):

How reproducible:
Usually

Steps to Reproduce:
1. kill -9 all slapd
2. Check to see whether /var/lib/ldap/ has __db* files
3. Try start openldap again. See whether the server work properly
  
Actual results:
The server crash

Expected results:
Server run smoothly

Additional info:

Comment 1 Somsak Sriprayoonsakul 2006-05-23 17:21:51 UTC
I modify /etc/init.d/ldap and add db_recover command to recover the database if
unclean commit is detected.

### just before starting daemon ###
if [ -f /var/lib/ldap/__db.001 ]; then
   /usr/bin/db_recover -h /var/lib/ldap
fi
# Start daemons
....

Comment 2 RHEL Program Management 2007-06-19 08:15:43 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 7 errata-xmlrpc 2007-11-15 16:04:03 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2007-0739.html