Databases Reference
In-Depth Information
SettING the NLS_Date_FOrMat OS VarIaBLe
By default RMAN displays the date information only (in its output). To include the time component in the RMAN
output, we recommend that you set NLS_DATe_FORMAT=”DD-MON-RRRR hh24:MI:SS” at the OS level prior to
running RMAN, for example:
$ export NLS_DATE_FORMAT="DD-MON-RRRR HH24:MI:SS"
This is useful especially when checking the exact time an RMAN command ran as viewed in the RMAN output.
How It Works
Backing up a database with RMAN was designed to be simple. All the required configuration settings are
automatically set to sensible defaults. Therefore, you can perform basic backup and recovery tasks without any
configuration of your RMAN environment.
By default RMAN will allocate a channel and back up to a location on disk. The default location is operating
system dependent. The list backup command will show you where the backup piece files are located.
If you want to specify a location for your backup pieces, you can stipulate this either by enabling a fast recovery
area as described in Chapter 3 or by specifically setting the backup location through the format command described
in Chapter 5.
Simulating a Failure
Problem
You want to simulate a failure as a prelude to testing RMAN's restore and recovery capabilities.
Solution
To simulate a failure, perform the following steps:
1.
Ensure you have a backup.
2.
Determine the location and name of a data file to rename. You will simulate media failure
by renaming a data file so that it appears to have been lost.
3.
Stop the database.
4.
Rename a data file at the OS level (simulates media failure).
5.
Attempt to start the database.
Before simulating a media failure, ensure that you're in a noncritical test database environment and that you
have a good RMAN backup of your database. Run the following command in your target database, and ensure that
you have a good backup:
$ rman target /
RMAN> list backup;
 
Search WWH ::




Custom Search