Oracle RMAN

CxLink Backup can be executed as an RMAN plugin by configuring your RMAN environment with the provided library under /opt/emory/lib directory.

Once RMAN environment is properly configured, you can execute backup, restore and archivelog operations using RMAN.

Topics


Configure RMAN environment

Before you can start using CxLink Backup For Oracle RMAN, you will need to ensure that the following configuration is applied to your RMAN environment.

As SBT channel devices are used to perform backup operations, you need to configure them to load corresponding CxLink Backup For RMAN library /opt/emory/lib/libemoryora.so.


SBT channels

Minimum configuration for your SBT channels is to specify where CxLink Backup For RMAN library is by executing configure command from RMAN client:

CONFIGURE CHANNEL DEVICE TYPE sbt PARMS='SBT_LIBRARY=/opt/emory/lib/libemoryora.so';

And, for your convenience, specify SBT device as the default one for backups:

CONFIGURE DEFAULT DEVICE TYPE TO sbt;

You can configure other parameters like parallelism, autobackup etc by following Oracle documentation from Oracle Help Center.

Parallelism

CxLink Backup for RMAN supports parallelism by using multiple sbt channels.

You can allocate them manually:

RUN {
  ALLOCATE CHANNEL c1 DEVICE TYPE sbt PARMS 'SBT_LIBRARY=/opt/emory/lib/libemoryora.so';
  ALLOCATE CHANNEL c2 DEVICE type sbt parms 'SBT_LIBRARY=/opt/emory/lib/libemoryora.so';
  ALLOCATE CHANNEL c3 DEVICE type sbt parms 'SBT_LIBRARY=/opt/emory/lib/libemoryora.so';
  ALLOCATE CHANNEL c4 DEVICE type sbt parms 'SBT_LIBRARY=/opt/emory/lib/libemoryora.so';
  BACKUP FULL DATABASE TAG FULL_ONLINE_BACKUP;
  RELEASE CHANNEL c1;
  RELEASE CHANNEL c2;
  RELEASE CHANNEL c3;
  RELEASE CHANNEL c4;
 }

Or you can specify PARALLELISM parameter under channel configuration to have automatic channel allocation:

CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 4 BACKUP TYPE TO BACKUPSET;

Backup Lifecycle

Expiration dates are CxLink Backup managed.

You can configure lifecycle as explained in Backup Lifecycle & Housekeeping section.

Backups will be created with the corresponding calculated expiration date and RMAN will expire them at that date.

Other configurations

You can also configure compression, encryption and many other interesting RMAN parameters, all of them compatible with CxLink Backup For RMAN solution.

More information on Oracle Help Center pages.


Backup your database

Once CxLink Backup agent is installed and RMAN parameters configured, you can initiate backup using RMAN:

BACKUP FULL DATABASE TAG FULL_ONLINE_01;

In the example a full online backup is started and labeled as FULL_ONLINE_01 but you can follow backup related documentation from Oracle Help Center.


Restore your database

To restore your database you can use any of the backup images from RMAN catalog. List command will show you available images:

RMAN> list backup summary;

List of Backups
===============
Key     TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
------- -- -- - ----------- --------------- ------- ------- ---------- ---
144     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
145     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
146     B  F  X SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
147     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
148     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
149     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
150     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
151     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
152     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01
153     B  F  A SBT_TAPE    14-NOV-23       1       1       NO         FULL_ONLINE_01

For example, you can restore full backup database labeled as FULL_ONLINE_01

RESTORE DATABASE FROM TAG FULL_ONLINE_01;

And then recover:

RECOVER DATABASE;

This is a very basic example; you can recover to a point-in-time or even to a certain log sequence number. Read Oracle documentation for detailed information.

Oracle Help Center:

Restoreopen in new window


General recommendations

Maintain an external RMAN recovery catalog

As Oracle recommends, a recovery catalog in an external Oracle database should be maintained. This will ensure a quick database recovery in case of disaster.

Use Disaster Recovery storage provider only if necessary

You can configure a Disaster Recovery storage provider; this will download CxLink Catalog from configured location and will use it in case of restore.

Use this feature ONLY to restore from a recovery location (i.e. in case of a total lost of your database). As soon as you recovered the database just remove the configuration. RMAN catalog maintenance won't be properly working due to possible differences between RMAN catalog and CxLink Backup catalog (i.e. removing backups from RMAN using delete will fail).

Where are your backups stored?

Your backups will be stored in the target bucket following these formatting:

<DB>/<year>/<month>/<day>/<RMAN_backup_file_name>

All backup files from the same backup will have the exact same suffix. These can help you to identify the objects of a specific backup.

Example: LNK/2023/11/15/bfgwodzu_1_1