flash_recovery_area full-- how do you use RMAN to delete directories of .arc files

About a week ago we turned archivelog mode on in an 11g oracle server.  The flash_recovery_area is now full, and redo logs can't be archived, so the database won't open.

I need to delete some of the dated directories containing the .arc files using rman.  What is the exact process for connecting using rman and for deleting these directories?

Also-- I use dbconsole to RMAN to backup the database to local disk, and Computer Associates Arcserve to backup to tape.  I expected the archivelogs to be deleted (like they are truncated in MS SQL server) when a backup is done.  Is this not a correct expectation?

I've read that one can also free up space by backing up components of the flash_recovery_area.  I can only do this to disk.  Anyone know exactly the complete correct syntax for rman?
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Richard OlutolaConsultantCommented:
FRA should be automatically managed. However, if this fails, you can use the following methods to free up space.

Log into RMAN in a command shell

Assuming you're on Linux/Unix

export ORACLE_SID=<sid>

rman target /

You should now be in RMAN CLI (Command Line Interface)

Show all;
This will show you all configured persistent settings. What you want to watch is RETENTION POLICY. Make sure this is not set to some ridiculous value. You may need to adjust this parameter to a more acceptable value like RECOVERY WINDOW OF 5 DAYS

One this is set (or if the the current setting is acceptable), now run the following commands:

crosscheck database;
crosscheck archivelog all;
delete noprompt expired archivelog all;
delete noprompt obsolete;
delete noprompt expired backup;

These commands should free up space for you by reclaiming the space from redundant backups according to you backup policy.

Finally, when you issue the backup database command in RMAN, I always backup the archivelogs at the same time and then delete the backed-up archivelogs in one command as follows:

RMAN> backup database plus archivelog delete input;

Without this command, if you use FRA for your archivelogs, you may run into space issues.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Here are som useful commands:

-find backupset to be deleted.
RMAN> list backup of database summary;

RMAN> list backupset 123;

RMAN> delete backupset 123;

SQL> SELECT object_type, message_type, message_level,
reason, suggested_action
FROM dba_outstanding_alerts;

The following actions can be done to resolve the space issue :
- Add disk space to the Flash Recovery Area.
- Back up your files to a tertiary device.
- Delete the files from the Flash Recovery Area using RMAN.
- Changing RMAN retention policy. If you are using Data Guard, then consider changing

The database handles a Flash Recovery Area with insufficient reclaimable space  just as it handles a disk full condition. Often, the result is a hang of the database.

To free space in the FRA, use command BACKUP RECOVERY AREA.
This command will take the backup of al the files in the FRA to tape only.
After this the space occupied by the files in the FRA will be marked as reclaimable.

RMAN> backup recovery area;

If you deleted files via OS then use RMAN CROSSCHECK.

Read more:
Metalink-notes: 305812.1 , 401163.1 , 305817.1 and 315098.1
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Oracle Database

From novice to tech pro — start learning today.