Subject | Re: Unique Constraints being violated in Firebird |
---|---|
Author | Adam |
Post date | 2006-07-05T23:23:07Z |
--- In firebird-support@yahoogroups.com, "Ann W. Harrison"
<aharrison@...> wrote:
Is it then safe to assume that the OS will flush the cache in the
order it is written? If not, it would be possible for the transaction
to be committed but not yet on disk, and the TIP may be written to
disk before the data page but something bad could happen before the
entire cache is flushed. Careful writes only work afterall if the OS
and hardware obey the fact you want carefully ordered writes. Still I
agree this is unlikely.
I am more interested about the fact (as per another message) that he
has run out of RAM in combination with the fact forced writes are
disabled, and he appeared to be under the impression that asynchronous
writes was still able to maintain durability and prevent corruption.
Adam
<aharrison@...> wrote:
>Hi Ann,
> Adam wrote:
> >
> > If Firebird happens to write the data to the data page before
> > populating the index page (is this possible??) and there is a problem
> > such as hardware failure before the index is updated then I can see
> > this happenning.
>
> The problem with that theory is that the failure would have prevented
> the transaction that entered the bad value from being committed. An
> uncommitted duplicate would not cause an error.
Is it then safe to assume that the OS will flush the cache in the
order it is written? If not, it would be possible for the transaction
to be committed but not yet on disk, and the TIP may be written to
disk before the data page but something bad could happen before the
entire cache is flushed. Careful writes only work afterall if the OS
and hardware obey the fact you want carefully ordered writes. Still I
agree this is unlikely.
I am more interested about the fact (as per another message) that he
has run out of RAM in combination with the fact forced writes are
disabled, and he appeared to be under the impression that asynchronous
writes was still able to maintain durability and prevent corruption.
Adam