•
Preparing for Database Backup to Oracle Cloud
Create a backup configuration to backup a database to Oracle Cloud Infrastructure
Object Storage.
•
Backing Up a Database with the CLI
Create a level 0, level 1, or LongTerm database backup with the command-line
interface.
•
Recovering a Database with the CLI
Recover the database to the system using a Backup Report, point-in-time recovery
(PITR), a system change number (SCN), or from the latest backup time.
•
Restoring a Database with the CLI
Restore a database to a system from Oracle Object Storage using a Backup
Report and the command-line interface.
Preparing for Database Backup to Disk
Use the command-line interface to create a policy to backup a database to the Oracle
Fast Recovery Area (FRA) of a disk.
You can create a backup policy using the Web Console or the command-line interface.
Most of the backup and recovery commands enable you to provide either a resource
name or resource ID to identify the database.
Backup to disk or the Backup to Internal FRA option in the Web Console, requires a
lot of disk space (up to two to three times the size of the database).
Follow these steps to create a backup policy through the command-line interface:
1.
Create a BackupConfig object (backup configuration) using the command
odacli
create-backupconfig
.
The backup configuration defines the backup, including the location where you
want to store the backups and the recovery window.
The following example creates a backup configuration named
mkg1dailydisk
with
a backup to
disk
and a 1 day recovery window.
# odacli create-backupconfig -d Disk -n mkg1dailydisk -w 1
2.
Check the job status.
# odacli list-jobs
When the job completes successfully, the backup configuration is ready.
3.
(Optional) Update an existing database to attach the backup configuration to the
database using the ID or Name.
When you attach the backup configuration to a database, the
dcs-agent
schedules daily automatic backups for the database.
The following example uses the Database Resource ID and Backup Configuration
ID:
# odacli update-database -i d3c4d8f6-5eb7-4f9e-ab27-7bdd5013ac90
-bi 9d942e0a-ba00-4cbc-9bfb-0de83ed279e5 -bp
Chapter 11
Using the CLI to Backup, Restore, and Recover
11-15
Summary of Contents for Database Appliance X6-2-HA
Page 15: ...Index xv...