Solved

Oracle 11g: archive logs management

Posted on 2013-05-27
4
776 Views
Last Modified: 2013-06-06
What is the best practice for archive logs management?
Partition for archive logs is getting filled up and it's well known that database stops when partition is full.

Is there a log rotation similar to mechanism presented in Linux?
Aren't archive logs deleted automatically after backup?
0
Comment
Question by:marianhe
  • 2
4 Comments
 
LVL 12

Accepted Solution

by:
praveencpk earned 450 total points
ID: 39198618
You can configure in rman for auto deletion or archivelog i.e

rman>CONFIGURE ARCHIVELOG DELETION POLICY TO applied on standby;

or

you can use delete archivelog command in your backup scripts.

rman>RUN
{
  # manually allocate a channel, in order to specify that the backup run by this
  # channel should go to both pools "first_copy" and "second_copy"
  ALLOCATE CHANNEL c1 DEVICE TYPE sbt
      PARMS='ENV=(NSR_DATA_VOLUME_POOL=second_copy)';
  ALLOCATE CHANNEL c2 DEVICE TYPE sbt
      PARMS='ENV=(NSR_DATA_VOLUME_POOL=first_copy)';
  BACKUP CHANNEL C1 ARCHIVELOG UNTIL TIME 'SYSDATE'
    NOT BACKED UP 2 TIMES # back up only logs without 2 backups on tape
    TAG SECOND_COPY;
  BACKUP CHANNEL C2 ARCHIVELOG UNTIL TIME 'SYSDATE'
    NOT BACKED UP 2 TIMES # back up only logs without 2 backups on tape
    TAG FIRST_COPY;
}

# now delete from disk all logs that have been backed up to tape at least twice
DELETE ARCHIVELOG ALL
  BACKED UP 2 TIMES TO DEVICE TYPE sbt;

check these doc for refferences.

http://www.di.unipi.it/~ghelli/didattica/bdldoc/B19306_01/backup.102/b14191/rcmbackp009.htm

http://www.dbasupport.com/forums/showthread.php?61244-rman-CONFIGURE-ARCHIVELOG-DELETION
0
 
LVL 77

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 50 total points
ID: 39201080
>>Aren't archive logs deleted automatically after backup?

As mentioned above:  No.  Not unless you tell the backups to delete them.

>>What is the best practice for archive logs management?

Personally, I keep as many of them around on disk as I can for as long as I can.  How long for you depends on your backup strategy and tape rotation.

IMHO, you want as many copies of your archived redo logs on as many tapes that you can afford.
0
 

Assisted Solution

by:marianhe
marianhe earned 0 total points
ID: 39213127
I've managed to set up archive logs management using Enterprise Manager console.
0
 

Author Closing Comment

by:marianhe
ID: 39224977
Enterprise Manager console is solution for those who prefer GUI to CLI.
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question