[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Corruption on deadlock?



At 01:01 PM 12/21/2005, Digant C Kasundra wrote:
>Maybe this is more of a BDB question instead of an OpenLDAP question,
>but perhaps OpenLDAP is doing some error handling so I thought I'd ask.
>
>I know if my bdb complains about memory allocation errors, I can bet
>that the changes it was making during that time are gone forever.  But
>what about the following error:
>
>bdb_idl_insert_key: c_get failed: DB_LOCK_DEADLOCK: Locker killed to
>resolve a deadlock (-30995)
>
>Do I need to go back in and check for consistancy to make sure it didn't
>drop any writes?

In general using back-bdb or back-hdb adhere to basic ACID
principles of databases.  If the client received a response,
then it knows whether the change was applied or not.  If
the change was applied, the new state endures.  If the
change was not applied, the old state endures.   Only
if the client did not receive a response is further
checking is required to determine if the update was applied
or not.

When deadlocks occur, the server retries.  You won't get
a response until it either completes or outright fails.