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

Re: bdb db / cache locking problem (ITS#3201)

>>I wonder if this problem shows up sooner if you have a very small entry
>>cache set.

> I tried two entry cache sizes. small (1000) and large (32K - which covers
> all).
> By now, I could observe this case only with the small entry cache.

OK... I've duplicated this problem by running test008 with cachesize set 
to 2 entries. modrdn crashes consistently in this case.

The problem is that the cache only uses locking to determine whether an 
entry is idle or not, but locks only protect us from interference from 
other threads. In the case of modrdn, it is this operation itself, 
within a single thread, that is touching many entries and so churning 
the entry cache. Looks like we need to add a refcounter back to the 
EntryInfo. (slaps forehead...)
   -- Howard Chu
   Chief Architect, Symas Corp.       Director, Highland Sun
   http://www.symas.com               http://highlandsun.com/hyc
   Symas: Premier OpenSource Development and Support