Subject Re: [firebird-support] Re: Corrupt database
Author Helen Borrie
At 11:38 PM 28/01/2005 +0000, you wrote:


>I know this. I was obviously referring to the gap. These sorts of
>tables have a habit of filling up really quickly, and each insert it
>probably in a different transaction.
>
>The setting just means every 20000 transactions, automatically sweep.

No, it doesn't. It means "when the gap between the oldest transaction and
the oldest active transaction reaches 20000, start a sweep in the next idle
time".

>Whether that means on transaction 20000,40000,60000, or whether it
>means that every time you sweep it is flagged to currenttransaction +
>20000, I don't know (or care).

If you are seeing a lot of auto-sweeping going on, you need to both know
and care. You need to know what your applications are doing to cause the
sweep threshold to be reached so often and, if it is impacting performance,
you need to care enough to mend the application code.

>I am only suggesting that his problem may stem from the sweep running, so
>switching off the automatic sweep and running it at 2am in a scheduled
>task when no-one is using the database may help.

It will be helpful where the nature of the application code is such that
the necessary sweeping becomes too pervasive to be practical. But the
manual sweeping -- under these conditions probably more frequently than
once a day -- becomes imperative. Databases with well-behaving applications
and autosweep enabled never get swept.

./heLen