Also my understanding is that when we give the alter tablespace end backup
command all the redo generated during the backup is applied to the datafile to
advance the datafile SCN to database SCN.
is absolutely wrong -- have you ever had an end backup ask you for an archive?
Nope, never will - we constantly write to the datafiles during the hot backup.
The SCN recorded in the header tells us how far back in the redo stream one
needs to go to recover this file.
Read the answer above again -- things like:
Lets say they are and the OS blocking read factor is
512bytes (the OS reads 512 bytes from disk at a time). The backup program goes
to read an 8k Oracle block. The OS gives it 4k. Meanwhile -- DBWR has asked to
rewrite this block. the OS schedules the DBWR write to occur right now. The
entire 8k block is rewritten. The backup program starts running again
(multi-tasking OS here) and reads the last 4k of the block.
should definitely make it clear that the datafiles are WRITTEN do whilst they
are being backed up (else we would not have this redo issue at all -- the
logging of the full block image)