Pavan DBA's Blog

The DBA Knowledge Store

Posts Tagged ‘rman backup behaviour’

How RMAN take backup?

Posted by Pavan DBA on March 28, 2013

Today I want to share what I know about RMAN backup behaviour in different versions.

Behaviour in 9i or below versions (which uses dictionary managed tablespace):

Normally there is a misconception that RMAN will take backup of only USED blocks.

But, during database backup, RMAN will take backup of both USED and FREE blocks also. Why and How this happens?


When we initiate RMAN to take backup of dictionary managed tablespace, it will read all the blocks from datafile into memory (which we usually call as input buffers). While doing this, RMAN will read all the blocks which are written by Oracle processes at some point of time i.e if a block is filled with data one month back and may be due to some delete/drop/truncate operation now the block is empty, still RMAN will count that block for backup.

By this we can understand that RMAN will read blocks with data and blocks without data also into memory.

Then which blocks RMAN will skip? BLOCKS WHICH ARE NEVER WRITTEN i.e if a block is UNUSED and no oracle process has written anything to it, then RMAN will skip those kind of blocks.


An immediate question that raises after above statement is why RMAN is doing this?

Because RMAN is designed in such a way that it can take backup even if database is in closed state (we know this already). Now, if the database is closed, RMAN cannot read data dictionary to get information like if the block is on freelist or not. So, RMAN will skip only UNUSED (never written) blocks.
This behaviour is completely changed in 10gR2 with the usage of locally managed tablespaces (from 10g by default a tablespace will be locally managed) which can maintain the block information in bitmap headers itself. So, in 10g, RMAN will take backup of only USED blocks leaving FREE and UNUSED blocks.

Note: The above behaviour is applicable also in 9i/8i if you use LMT.


Posted in RMAN | Tagged: , | 6 Comments »

%d bloggers like this: