Creating Backup Sets   «Prev  Next»

Lesson 6Data file backup sets
ObjectiveIdentify data file backup sets.

Data file backup sets

How do I identify data file backup sets in Oracle 12c?
Oracle provides a robust system for managing and interacting with backup sets, through a component of Oracle Recovery Manager (RMAN), an Oracle Database client that performs backup and recovery tasks on your databases.
RMAN backup sets are typically composed of one or more physical files, each holding the backup data for one or more datafiles, control files, or archived redo logs. Each backup set contains the data from a single run of a BACKUP command.
To identify data file backup sets in Oracle 12c, you can use the RMAN LIST command. This command provides detailed information about backup sets, copies, and pieces. Here's how you can use it:
Start the RMAN client and connect to your Oracle Database instance as a user with SYSDBA privileges. You can do this with the following commands:
CONNECT TARGET SYS/[password]@target_db AS SYSDBA;

Replace [password] with the actual password for the SYS user, and target_db with the name of your Oracle Database instance.
Run the LIST BACKUP command to display information about backup sets. Here's an example:

This command lists all backup sets of datafile 1.
For a more detailed report, use the SUMMARY keyword:

This command lists a summary of all backup sets.
Please note that if you're using a recovery catalog, RMAN will retrieve the backup metadata from the recovery catalog. If you're not using a recovery catalog, RMAN will retrieve the backup metadata from the control file of the target database.
By using the LIST command, you can identify and manage your data file backup sets in Oracle 12c effectively. However, always ensure that your Oracle database is correctly backed up and the backup sets are verified to prevent any data loss.
In this lesson, we will take an in-depth look at the different types of backup sets you can create.

Data file backup set

In an Oracle8 database, a table is kept in a tablespace, and a tablespace can contain one or more data files on disk. You can back up an entire database, a tablespace, or a data file. When you back up a data file with Recovery Manager, the database must be open.
You can specify a data file in a backup spec in one of two ways :
  1. Including its pathname in single quotes, such as:

datafile 'oracle/dbs/tablesp_1.f'

  1. Identifying it by its file number, such as:

datafile 1

You can get a listing of absolute file numbers by issuing the command report schema in Recovery Manager.
If you back up the data file with the absolute file number of 1, the control file for the database is also included in the backup set.

Parallelism and datafiles

For data files, the use of parallel processes to back up the data files is pretty straightforward. Each data file can use a separate channel; you can use the filesperset option to split up the data files among multiple available channels; or you can assign a particular backup set to a single channel.
In the next lesson, you will learn about archive log and control file backup sets.