Database Reference
In-Depth Information
Table 4-2. ( continued )
Decision Point
Implementation in Script
Line Number in Script
6. Setting the autobackup of the
control file
Enabled in the script
Line 32
7. Specifying the location of the
autobackup of the control file
Placed in the same directory as the
backups
Line 33
8. Backing up archive redo logs
Backing up with the rest of
the database; specifically,
using the PLUS ARCHIVELOG clause
Line 38
9. Determining the location for the
snapshot control file
Using the default location
N/A
Line 26, connecting as nocatalog
10. Using a recovery catalog
Not using
Lines 35-37, device type disk
11. Using a media manager
Not using
12. Setting the CONTROL_FILE_RECORD_
KEEP_TIME initialization parameter
Using the default
N/A
13. Configuring RMAN's backup
retention policy
Configuring to a redundancy of 1,
cross-checking, and deleting obsolete
backups and archive redo log files
Line 34, configuring; lines 30 and
31 cross-check; line 39, using
RMAN to delete old files
14. Configuring the archive redo logs'
deletion policy
Using the same retention policy applied
to the backups
N/A
15. Setting the degree of parallelism
Setting a degree of 2
Lines 35-37
16. Using backup sets or image copies
Using backup sets
Line 38
17. Using incremental backups
Incremental level 0, the same as a full
backup
Line 38
18. Using incrementally updated
backups
Not using
N/A
19. Using block change tracking
Not using
N/A
20. Configuring binary compression
Using basic compression
Line 38
21. Configuring encryption
Not using
N/A
22. Configuring miscellaneous settings
Not using
N/A
23. Configuring informational output
Setting
Lines 15, 28, and 29
A few aspects of this script need further discussion. Lines 9, 10, and 11 set the required OS variables by hard-
coding the required OS variables into the script (see Chapter 1 for details on sourcing OS variables). I generally prefer
not to hard-code variables into a script like this, but did so here to provide a simple example of how to script RMAN to
backup your database. You'll find that many DBAs do hard-code these variables into scripts.
Line 15 sets the NLS_DATE_FORMAT OS variable to a value that includes hours, minutes, and seconds. This ensures
that when RMAN runs commands that are appropriate, it displays the date output with a time component. This can
be invaluable when you're debugging and diagnosing issues. By default, RMAN displays only the date component.
Knowing just the date when a command ran is rarely enough information to determine the timing of the commands
as they were executed. At minimum, you need to see hours and minutes (along with the date).
 
 
Search WWH ::




Custom Search