Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Instance Recovery Question

Re: Instance Recovery Question

From: Jeremiah Wilton <jeremiah_at_wolfenet.com>
Date: Sat, 5 Dec 1998 21:07:16 -0800
Message-ID: <Pine.OSF.3.95.981205204359.7990B-100000@gonzo.wolfenet.com>


On Sat, 5 Dec 1998 mpir_at_compuserve.com wrote:
>
> Actually, until the commit is issued, the data is not written to the
> 'permanent' table block but is in the rollback segment block. Answer 1 is
> correct.

Actually, during a transaction, the before-images of the changed data are moved to the rollback segment, and the new stuff is placed in the data blocks. If it worked the way you describe, we would be waiting all day whenever we commit for the bits to get copied around. This is why commits are nearly instantaneous and rollbacks can take a long time.

> On commit, the rollback block is freed only after the table block is written.
> Should an instance fail between commit and rollback marked free, the block
> will be rewritten to the table.
>
> We now enter the mystical and mythical territory of system buffer flushes,
> that is data corruption because Oracle wrote to the disk, but the system did
> not flush its buffers to disk. You cannot eliminate this risk (even with
> direct raw files), just get it to a minimum. There is no recovery, hence the
> magic of backups and archives.

I isn't mystical or mythical! A commit won't return unless it has written to redo, meaning it can be recovered during crash recovery, regardless of your archive mode. If you didn't commit, then your transaction will roll back as soon as the crashed instance comes up again. In Oracle there are only "committed" and "not committed." There is no in-between.

--
Jeremiah Wilton http://www.wolfenet.com/~jeremiah Received on Sat Dec 05 1998 - 23:07:16 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US