Bug 5105 -- patch?

Volker Lendecke Volker.Lendecke at SerNet.DE
Tue Dec 4 15:23:20 GMT 2007

On Tue, Dec 04, 2007 at 08:55:42AM -0600, Gerald (Jerry) Carter wrote:
> > On Sun, Nov 25, 2007 at 10:41:43AM +0100, Volker Lendecke wrote:
> >> In response to Bug 5105 I coded up the attached patch. Do we
> >> want such a thing? It right now limits the allowed hash
> >> chain length to a million and the freelist length to 10
> >> million.
> > 
> > No comment here?
> Hey Volker,
> Just trying to understand.  From what I see the patch defines
> two max values for freelist and hash chains and simply verifies
> that the two tdb values don't increase beyond that.  Right?
> I don't spend a lot of time in tdb, so I'm curious if I my
> analysis of the patch is correct.

Facing a corrupt tdb with a cyclic freelist or a cyclic hash
chain this patch turns the endless loop spinning those
cycles into high CPU load.

> How likely is your comment, "...but it also might render some valid
> tdb's as invalid."?

Well, how likely is a tdb with a million entries in a hash
chain? With 131 chains as default this would be a tdb with
more than 10 million entries before it gets likely to have
such a long chain. Users will have seen a severe performance
degradation long before that.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20071204/cb3a9137/attachment.bin

More information about the samba-technical mailing list