Oracle Database 11g offers clone source DB without requiring backup. Prior to 11g you had to take physical backup on disk/tape, however now you can create a clone DB over the network without prior backup.
In 11g, a new feature called RMAN Active database duplication has been introduced to clone a database without a physical backup. The clone can be performed over the network. In this blog, I will share more about this feature.
Active database duplication copies the live target database over the network to the auxiliary destination and then creates the duplicate database. The only difference from traditional duplication is that we don't need to have the pre-existing RMAN backups and copies. The duplication work is performed by an auxiliary channel. This channel corresponds to a server session on the auxiliary instance on the auxiliary host.
Starting from 11g we can utilize duplicate database in two ways.
- Active database duplication
- Backup-based duplication
Img Source: http://bit.ly/2dY85EJ
As part of the duplicating operation, RMAN automates the following steps:
- Creates a control file for the duplicate database.
- Restarts the auxiliary instance and mounts the duplicate control file.
- Creates the duplicate datafiles and recovers them with incremental backups and archived redo logs.
- Opens the duplicate database with the RESETLOGS option.
For the active database duplication, RMAN does one extra step .i.e. copy the target database datafiles over the network to the auxiliary instance.
Basic Steps to ACTIVE database duplication are:
- Preparing the auxiliary instance.
1.1 Creating initialization Parameter file for the Auxiliary instance.
1.2 Create an Oracle Password File for the Auxiliary Instance.
1.3 Establish Oracle Net Connectivity to the Auxiliary Instance.
The auxiliary instance must be available through Oracle Net if we are duplicating from an ACTIVE database.
Start the Auxiliary instance from Sqlplus
Use SQL*Plus to connect to the auxiliary instance and start it in NOMOUNT mode.
SQL> startup NOMOUNT pfile=initTEST.ora
ORACLE instance started.
In this Doc we are doing duplicate database from the
auxiliary server. Look at the example-:
RMAN> connect TARGET sys / sys @ PROD; ## Target database ##
connected to target database: PROD (DBID=1450838187)
RMAN> connect AUXILIARY sys / sys @ TEST ; ## Auxiliary database ##
connected to auxiliary database: TEST (not mounted)
RMAN> connect CATALOG rman / rman @ CAT ; ## Catalog database .Optional ##
connected to recovery catalog database
The simplest case is to use active database duplication to duplicate the database to a different host and use the different directory structure. For example:
RMAN> DUPLICATE TARGET DATABASE
FROM ACTIVE DATABASE
Oracle Database 11g offers clone source DB without requiring backup. Prior to 11g you had to take physical backup on disk/tape, however now you can create a clone DB over the network without prior backup. For any questions on the topic click below. You can also leave a comment in the field below.