What is Flash Recovery Area ??
FRA is a special area on disk that is used by
the database as a backup location.By default RMAN creates
backups of all types – regular backup sets, image copies, and archive logs – in
that area.Since RMAN knows about the existence of this area,it automatically
deletes unneeded backups based on redundancy and retension periods to make room
for new backups.
In addition to backups, the flash
recovery area can also store online redo log files, archived redo log files,
and control files. Again, these are optional; you can always define the location
of those files to be anywhere, not necessarily inside the flash recovery area. Since
the flash recovery area is generally used for backup files, you should consider
creating it on disks different from your main database disks. Doing so
helps protect you from losing both your main database and your backup files
from a single failure. You can further take advantage of this probability by
putting one member of the redo log group or one control file on the flash recovery
area. This reduces the possibility of all members of a redo log group or all
control files getting damaged at the same time.
How to create the FRA ??
Things to consider
before creating the FRA:
- · FRA Size:Depends on the size of backups , archive logs etc
- FRA location: As a best practice you should avoid putting the FRA and the database files on the same mount point or disk group (if on ASM).
Having
the answers to these questions in mind, you can then use the following process
to create the flash recovery area:
Disable the parameters log_archive_dest and log_archive_duplex_dest, if they are set in the database. You can do that by issuing the following commands:
Disable the parameters log_archive_dest and log_archive_duplex_dest, if they are set in the database. You can do that by issuing the following commands:
alter system set
log_archive_duplex_dest = '';
alter system set
log_archive_dest = '';
Log
on as a user with the sysdba role and issue
the following commands to size and create the flash recovery area:
alter system set
db_recovery_size = 4G;
alter system set
db_recovery_dest = '/home/oracle/flasharea';
The sequence of these commands is
important; you have to issue them in that order, not
the reverse. However, do replace the size and path name with the values you
have chosen for your system.That’s it; the flash recovery area is ready for
operation.
Remember, you can always define a
different location for archived redo logs. If you use a different location,
then you can’t just erase the values of the parameters log_archive_dest and log_archive_duplex_dest,
as suggested in the earlier solution:
alter system set
log_archive_duplex_dest = '';
alter system set log_archive_dest =
'';
To place your log
files elsewhere than the flash recovery area, you should use a different parameter
to specify the archived redo log location; use log_archive_dest_1 instead of log_archive_dest.
Suppose log_archive_dest used to be /dbarch. You can use log_archive_dest_1 to
specify the same location for archived redo logs. First, check the value of the
parameter log_archive_dest:
SQL>show parameter log_archive_dest
NAME TYPE VALUE
------------------------------------
----------- ----------------------------
log_archive_dest string /dbarch
The current setting of the archived
redo log destination is /home/backup/archives. Next, set the log_archive_dest_1
parameter to that location:
SQL> alter system set
log_archive_dest_1 = 'location=/home/backup/archives';
Now set log_archive_dest to NULL:
SQL> alter system set
log_archive_dest = '';
If you have set the two parameters—log_archive_dest
and log_archive_duplex_dest—in the initialization parameter file, you should
edit the file to remove these two parameters completely.
No comments:
Post a Comment