Subject | Re: [firebird-support] endless sweep |
---|---|
Author | Ann W. Harrison |
Post date | 2005-03-10T18:32:56Z |
> Ferda Brabenec wrote:Alexandre Benson Smith wrote:
>
>>thanks for the info. The sweep finished after 5 days.
>>I am a bit puzzled by the fact, that indices play such a big role in sweep
>>process. Is it because they contain references to already deleted records?
>>
>Here's the quick version. The index contains information for all
> I don't remember the real reason why sweep take a long time to run if
> you have a lot of duplicates, I think because the entire duplicate chain
> should be reached to look for the records on the data page, I am sure
> someone will jump in and explain the real reason with acuracy.
>
records in the table, including records that have been deleted and not
garbage collected. Records are normally stored from the front of the
table to the back, and garbage collected in the same order (FIFO). A
new duplicate index value is stored at the beginning of the list of
duplicates (LIFO). When the sweep finds a record to delete, it must
also find the corresponding index entry. It takes The first record it
sees is almost certainly going to be the last one in the chain of
duplicates, so it has to look at each one of the n-thousand duplicates.
In a bad case, you empty the cache
Regards,
Ann