Sunday, February 8, 2009

Oracle:Configure flash recovery area

in Oracle 10G, a major feature is flash recovery area.Flash recovery area contributes as a central repository for rman to store backups,archive logs. Even oracle recommends to keep your manual backups,archive logs,redo files to keep in FRA. We can keep control files also to this location.

Let us check what are the effective way to configure FRA(login as sysdba user):

step 1: To configure Flash recovery area , first you need to think about:
i) what will be the location
ii) what should be the size
step 2:
sql>show parameter log_archive_dest
sql>show parameter log_archive_duplex_dest
sql>show parameter log_archive_dest_
(check for the values for 1 to 10)
If this parameters have a value set then, you need to remove this values.
Normally we may have either log_archive_dest+log_archive_duplex_dest or log_archive_dest_1 to 10 set as archive location. Both combination are not allowed together.
any of these parameters , need to be removed to configure flash recovery area

Note: You may have this values configured as your archive log location, we will discuss about this point later

to remove the values:

sql> alter system set log_archive_duplex_dest = ' ' scope=both;
sql> alter system set log_archive_dest = ' ' scope=both;

for log_archive_dest_1 to 10 follow the same to remove the values.

step 3: Issue the following command:
sql>alter system set db_recovery_file_dest_size = 8G scope=both;
sql>alter system set db_recovery_file_dest = 'e:\oracle\flasharea' scope=both;

Note: the directory "e:\oracle\flasharea" should exists .

Now, the note earlier about archive log location.
if you have log_archive_dest as your archive log location , then change it to log_archive_dest_1 to store archive log.

check this ,
earlier location for archive log:

SQL>show parameter log_archive_dest
------------------------------------ ----------- ----------------------------
log_archive_dest string e:\archive

now change the value:

sql> alter system set log_archive_dest = ' ' scope=both;
SQL> alter system set log_archive_dest_1 = 'location=e:\archive';

Note that , With flash recovery area configured we can keep the archive log in that location(as of oracle recommendation), though if you want above is the solution for using flash recovery area as well as different archive locations for archiving redo logs.


Have a nice day....................

No comments: