Data Consistency, Recovery, and Migration 4-25
Blobspace Logging
OnLine allocates and deallocates blobpages via the blobspace free-map
pages. (Refer topage 2-148.) If a blobspace blob is deleted during a trans-
action,the entries in the free-map page for the blobpages storing the blob are
marked for deletion. The blob data is unchanged. If the transaction is
eventually rolled back, OnLine simply reverses the change to the blobpage
status in the free-map page entry. Even if the transaction is committed, the
blobpages remain protected until the logical log file in which the delete
occurredbecomes free. That is, the blobpages become “free” and available for
reuse only after logical log file in which the deletion occurred is no longer
neededfor a data restore. One consequence of this strategy is that you do not
seethe effect of deleting blobspace blobs to increase available space until you
free the logical log file in which the delete occurred.
Blob Restoration
Howcan a blobspace blob be restored if the logical log records do not include
the data?
Theanswer is that even though blobspace blobpages never pass through the
logical logfiles, blobpages are copied directly to the logical log backup tape.
OnLine performs the copying as part of the logical log backup procedure.
Whenyou request a logical log backup, you start the tbtape process. (If you
request the logical log backup throughDB-Monitor, the monitor process
tbmonitorstarts the tbtape process for you.) When the tbtape utility process
beginsa logical log backup to tape, it notes the logical log file ID. Next, tbtape
checks the blobspace free-map pages for every blobspace, looking for
blobpages that were allocated during the time that this logical log file was
current. The current logical log ID number is stored in the blobspace free-
map page each time a blobpage is allocated.
Thetbtape process copies each blobpage allocated when this logical log file
wascurrent to the backup tape before any logical log record is copied. Then
tbtapecontinues the backup procedure, copying to tape the records from the
logical log file. In this way,tbtape creates a permanent record of blobpage
data and associated logical log records without overburdening the capacity
of the logical log files.
For further information about what happens during the logical log backup
procedure, refer topage 4-26.