To clear db2 archive log after db2 database backup

After db2 backup archive log remains as it is.is there setting to remove archive logs after database backup.DAS is not installed.
DB2 9.1 FP 6
os HP unix

Hello Anand,
If the archvied logs are not required, ie they are not required for restore    
you can remove them. 
You can check this is by running                                                                               
db2 list history all for db <sid>                                                                               
The above command will give you a detailed overview of the backup           
history and what logs were archived and what logs were included or needed for restore of backups.
If they are no longer needed for a restore, then it is safe to remove them.
Kind regards,
Paul

Similar Messages

  • How to calculate storage space for archive log files and database backups?

    Hi all,
    I have a 1.8 terabyte Oracle 9i database and need to plan for how much additional disk space I will need to perform nightly backups and for archivelog files. Is there a script or formula available that can help me estimate how much required disk space I will need to hold a days worth of archived logs as well as a nightly export dump file and a full hot RMAN backup on disk?
    Thanks!

    I'm not sure how to estimate the size of your backups, especially if you use incrementals. However, the space required for archive logs will be equal to the amount of REDO your DB generates. I would count the number of log switches per day with a query like the following:
    select trunc(first_time), count(*)
    from v$log_history
    group by trunc(first_time)
    I would then take the average and multiply this count by the size of your redo log files (assuming they are all the same size).

  • Applying the arch logs after the full backup

    DB version:10GR2
    In NOCATALOG mode, I am going to take a full backup (Hot) of DBx (800gb) using the command
    run {
    allocate channel c1 TYPE DISK connect 'sys/dempo'  FORMAT   '/u04/bkp/stprod_%U.rbk';
    backup as compressed backupset database tag 'full'  plus archivelog;
    }and restore it into DBy.
    But how can i apply the archive logs generated in DBx during the full backup after the full backup?
    The restored control file doesn't know about these archived logs. Right?

    with controlfile autobackup off, the backup will be 'complete', as backing up a whole database means backing up it's system tablespace(1 st datafile to be exact, which is the part of system tablespace)The SYSTEM datafile (or multiple datafiles in SYSTEM) may be the first or the second or the nth datafile to be backed up. The BackupSet consisting of multiple backup pieces may have other tablespaces backed up after the SYSTEM datafile. Those other tablespaces and possible redo log switches have timestamps which succeed the SYSTEM datafile backup . Therefore, those other tablespaces and redo log switches are not captured in that controlfile backup that was included with the SYSTEM datafile.
    (Yes, I know we can use the controlfile backup --- but I am just pointing out that this doesn't meet the OP's requirement that the controlfile be aware of all redologs that have been switched during or after the database backup).
    Hemant K Chitale
    http://hemantoracledba.blogspot.com

  • RMAN: How to apply Archive Logs after recoverying of all physical files

    Hi;
    I am using RMAN Oracle10g; my test database has being corrupted. I have already taken 0 level backup through this command
    run {
    allocate channel c1 type disk;
    backup incremental level 0 tag = Test_Weekly_database format 'O:\rman\backup\Full_Weekly_%d_%s_%p_%t'(database);
    release channel c1;
    configure controlfile autobackup format for device type disk to 'O:\rman\backup\Auto_Ctrl_weekly_%F';
    allocate channel c1 type disk;
    sql 'alter system archive log current';
    BACKUP tag = Test_Weekly_Arch ARCHIVELOG UNTIL TIME 'SYSDATE-7' format 'O:\rman\backup\Archive_weekly_%d_%s_%p_%t';
    DELETE ARCHIVELOG UNTIL TIME 'SYSDATE-7';
    release channel c1;
    After backing up I inserted few records in TEST123 table. And switch current log file.
    Then my database has been corrupted. Now I have last 0 level backup (RMAN) and archive logs files on OS level.
    I am recovering my database with the following commands; but archive logs have not being applied. And my inserted records were not presented in TEST123 table.
    Kindly guide me
    SQL> startup nomount
    CMD> RMAN target=/
    RMAN>set DBID 1168995671
    RMAN>RUN {
    SET CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'O:\rman\backup\Auto_Ctrl_weekly_%F';
    RESTORE CONTROLFILE from autobackup;
    RMAN> ALTER DATABASE MOUNT;
    RMAN> RESTORE DATABASE CHECK READONLY;
    RMAN> RECOVER DATABASE NOREDO;
    RMAN> restore archivelog all;
    SQL> startup mount
    SQL> alter database backup controlfile to trace;
    SQL> shut immediate
    SQL> startup nomount
    SQL> CREATE CONTROLFILE REUSE DATABASE "ORCL" RESETLOGS ARCHIVELOG................;
    SQL> alter database open resetlogs
    ---Database altered.
    SQL> select * from TEST123;
    Not record found
    regards;
    Asim

    Dear Khurram;
    Kindly advise where i m worrg???????
    C:\>RMAN target=/
    RMAN> set DBID 1168995671
    executing command: SET DBID
    RMAN> RUN {
    2> SET CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'O:\rman\backup\Auto_Ctrl_weekly_%F';
    3> RESTORE CONTROLFILE from autobackup;
    4> }
    executing command: SET CONTROLFILE AUTOBACKUP FORMAT
    Starting restore at 27-DEC-07
    using channel ORA_DISK_1
    recovery area destination: O:\rman\backup
    database name (or database unique name) used for search: ORCL
    channel ORA_DISK_1: no autobackups found in the recovery area
    channel ORA_DISK_1: looking for autobackup on day: 20071227
    channel ORA_DISK_1: autobackup found: O:\rman\backup\Auto_Ctrl_weekly_c-11689956
    71-20071227-04
    channel ORA_DISK_1: control file restore from autobackup complete
    output filename=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\CONTROL01.CTL
    output filename=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\CONTROL02.CTL
    output filename=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\CONTROL03.CTL
    Finished restore at 27-DEC-07
    RMAN> ALTER DATABASE MOUNT;
    database mounted
    released channel: ORA_DISK_1
    RMAN> RESTORE DATABASE CHECK READONLY;
    Starting restore at 27-DEC-07
    Starting implicit crosscheck backup at 27-DEC-07
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=155 devtype=DISK
    allocated channel: ORA_DISK_2
    channel ORA_DISK_2: sid=154 devtype=DISK
    Crosschecked 9 objects
    Finished implicit crosscheck backup at 27-DEC-07
    Starting implicit crosscheck copy at 27-DEC-07
    using channel ORA_DISK_1
    using channel ORA_DISK_2
    Finished implicit crosscheck copy at 27-DEC-07
    searching for all files in the recovery area
    cataloging files...
    no files cataloged
    using channel ORA_DISK_1
    using channel ORA_DISK_2
    channel ORA_DISK_1: starting datafile backupset restore
    channel ORA_DISK_1: specifying datafile(s) to restore from backup set
    restoring datafile 00001 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\SYSTEM01.DBF
    restoring datafile 00002 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\UNDOTBS01.DBF
    restoring datafile 00003 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\SYSAUX01.DBF
    restoring datafile 00004 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\USERS01.DBF
    restoring datafile 00005 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\TEST.DBF
    restoring datafile 00006 to D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\TEST2
    channel ORA_DISK_1: reading from backup piece O:\RMAN\BACKUP\FULL_WEEKLY_ORCL_3_
    1_642420573
    channel ORA_DISK_1: restored backup piece 1
    piece handle=O:\RMAN\BACKUP\FULL_WEEKLY_ORCL_3_1_642420573 tag=Test_WEEKLY_DATAB
    ASE
    channel ORA_DISK_1: restore complete, elapsed time: 00:00:46
    Finished restore at 27-DEC-07
    RMAN> restore archivelog all;
    archive log thread 1 sequence 1 is already on disk as file O:\ARCHIVE\ARC00001_0642356125.001
    archive log thread 1 sequence 2 is already on disk as file O:\ARCHIVE\ARC00002_0642356125.001
    archive log thread 1 sequence 3 is already on disk as file O:\ARCHIVE\ARC00003_0642356125.001
    archive log thread 1 sequence 4 is already on disk as file O:\ARCHIVE\ARC00004_0642356125.001
    archive log thread 1 sequence 5 is already on disk as file O:\ARCHIVE\ARC00005_0642356125.001
    archive log thread 1 sequence 6 is already on disk as file O:\ARCHIVE\ARC00006_0642356125.001
    archive log thread 1 sequence 7 is already on disk as file O:\ARCHIVE\ARC00007_0642356125.001
    archive log thread 1 sequence 8 is already on disk as file O:\ARCHIVE\ARC00008_0642356125.001
    archive log thread 1 sequence 9 is already on disk as file O:\ARCHIVE\ARC00009_0642356125.001
    archive log thread 1 sequence 10 is already on disk as file O:\ARCHIVE\ARC00010_0642356125.001
    archive log thread 1 sequence 11 is already on disk as file O:\ARCHIVE\ARC00011_0642356125.001
    archive log thread 1 sequence 12 is already on disk as file O:\ARCHIVE\ARC00012_0642356125.001
    channel ORA_DISK_1: starting archive log restore to default destination
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=15
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=16
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=17
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=18
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=19
    channel ORA_DISK_1: restoring archive log
    archive log thread=1 sequence=20
    channel ORA_DISK_1: reading from backup piece O:\RMAN\BACKUP\ARCHIVE_WEEKLY_ORCL_5_1_642420630
    channel ORA_DISK_1: restored backup piece 1
    piece handle=O:\RMAN\BACKUP\ARCHIVE_WEEKLY_ORCL_5_1_642420630 tag=Test_WEEKLY_ARCH
    channel ORA_DISK_1: restore complete, elapsed time: 00:00:08
    Finished restore at 27-DEC-07
    RMAN> ALTER DATABASE OPEN;
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of alter db command at 12/27/2007 10:27:10
    ORA-01152: file 1 was not restored from a sufficiently old backup
    ORA-01110: data file 1: 'D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\SYSTEM01.DBF'
    Regards;
    Asim

  • Manually apply archived log to standby database.

    Hi all,
    I am working on oracle 10g EE(10.2.0.4).I am having a very difficult database switchover case in my hand.
    1.> There are two database .one primary(prim) and another standby(standby).
    2.> Initially both of them was configured as oracle data guard, where prim was primary and standby was standby using rman .(RMAN>duplicate target database for
    standby dorecover).
    3.>But the rate of generation of archivelog is very high( 20 archivelog per hour with 200mb each).
    4.> So automatic shipping of archivelog has been disabled from primary.(log_archive_dest_state_2=defer and nullifying the value of log_archive_dest_2).
    5> Now after a period of time archived logs are shipped to dr site manually and applied manually.(alter database recover automatic standby database;)
    6.> Now there is a hardware problem occured at primary..it will take 72 hours to come up.
    How can i use standby database as primary for that 72 hour.As archive log apply is manually done and parameters are being changed,can i switch over these two?
    Is it possible to switchover and switch back these two database with such a configuration?

    How can i use standby database as primary for that 72 hour.As archive log apply is manually done and parameters are being changed,can i switch over these two?
    Is it possible to switchover and switch back these two database with such a configuration?
    As of now you can perform failover your standby to primary database. you should have flashaback enabled, so you have to create a restore point.
    Then it can be opened in read & write mode, So once you finished again you can go back to that point.
    http://docs.oracle.com/cd/B19306_01/server.102/b14239/manage_ps.htm#i1017111
    The above case applicable if you ready to loose, But it doesnt make sense. But in your case this doesnt work. Because once you start use of Standby as primary, there would be live/production data, which you need very much.
    So there is lot of work to do.
    You have to rebuild standby database and then switchover back to same location. So its a little trip work.
    Have you enabled Dataguard Broker ?
    Edited by: CKPT on Mar 13, 2012 1:43 PM

  • Missing archived logs when recovering database

    Scenario is
    1-10 archived logs required to recover database.
    5 Number log is missing
    It means that 6,7,8,9,10 are useless for me
    yes/no Please explain it to me
    Thanks a Lot

    Hi,
    Yes all archivelog after the missing sequence of archivelog will be useless for recovery.
    in ur case 6,7,8,9,10 are useless for you.
    So only incomplete recovery is the solution.
    Thanks
    Kuljeet Pal Singh

  • Restoring archive log after cold backup

    Hello forums users,
    I read many thing on this topic but I didn't find the good answer.
    I performed a cold backup each sunday.
    My database is in ARCHIVE LOG mode.
    Is it possible to restore ARCHIVE LOG files after restoring COLD backup?
    Sunday : cold backup
    Monday : new archive log have been created since cold backup
    Tuesday : same as Monday
    Wednesday : I would like to restore to Monday 22:00 for example
    Can I restore cold backup + apply archive log until Monday 22:00 ?
    Regards,
    Guillaume

    recover database using backup controlfile until cancel|time|logseq|scn
    will do this and prompt you for the archivelogs.
    Known as 'incomplete recovery'
    Hth
    Sybrand Bakker
    Senior Oracle DBA

  • Applying Archive logs after restore by RMAN

    We user RMAN for our backup. I wanted to restore the database and apply all the archive logs.
    After I use
    RMAN> Restore database ( from last night backup)
    RMAN> Recover database
    And now I want to apply all the archive logs from which were generated from last night backup say 11:00 pm till 10:00 am today morning.
    How can I apply the archive logs.
    Thanks

    I have the RMAN backup on tape , and I have the archive logs on the disk , as the archive logs would be backed up only the following night.
    i.e i want to restore a 10th night backup , and apply the logs from 10th night 11:00 pm to 10:00 am 11th morning. As the archive logs would still be on the disk , how can I apply them..
    Thanks

  • Archive logs and recovering database with no RMAN

    Hello,
    I inherited a database with no RMAN backup activated but archive redo logs are activated and generating at every moment.
    As there is no rman backup I always thought that those archive redo logs were useless and because of reduced disk space, regularly I delete all of them.
    Then I read that archive redo logs can be usefull even if there is no RMAN. Archive redo logs can be used in a recovery situation like this:
    set all tablespaces in backup mode
    alter tablespace tsp1..tsp100 begin backup;
    copy all datafiles
    alter tablespace tsp1..tsp100 end backup;
    alter database create standby controlfile as 'c:\temp\sbytemp.ctl';
    copy of archivelogs from start begin backup time till nowAs I delete my archive logs, I don't have all ones from the first time. My question is:
    How many archive redo log files would I need to have? Would I need to have all archive logs that were generated from the first time? Or would be enough to have the last three or four ones?
    Thanks
    Edited by: user521219 on 21-may-2012 7:50

    How many archive redo log files would I need to have?
    Would I need to have all archive logs that were generated from the first time?
    would be enough to have the last three or four ones?You need all archive redo log from the moment you have started taking full backup.
    If you take full backup every night at 1:00 AM, you will need all archive redo logs that have transactions finished at and after 1:00 AM.

  • Corruption of archived logs after redo resizing - URGENT

    Hello all,
    We have a RAC 9i 2-node DB, running on RHEL 3 machines.
    We resized our redo logs from 100M to 1G to avoid "Can not allocate log, archival required" messages.
    The operation was successful, but now we are facing problems with the ext3 filesystem holding the archived logs.
    Each node has its own arc location, mounted only once.
    When we run "ls" in the arc destination, we get "ls: Input/output error" messages.
    RMAN complains also about corrupted arcvhived logs.
    The day before Yesterday we reformatted one arc destination, and today the messages appeared in the other one.
    Do you have any suggestion?
    Jonathan

    Did the problem occur right after increasing the log size? Then the first thing to do would be to decrease the log size, but add more log groups to fix the "Can not allocate..." problem.
    If "ls" doesn't work, your file system is stuffed.Reformat the archive dest and do simple file copies to verify the integrity, before putting the archive logs back on.
    That's just for starters...

  • Transfering archive logs in standby database

    hi,
    i am trying to create a standby database for a a test scenario using oracle 10g R2 and windows xp
    Primary DB = primary
    standby DB=stby
    iam able to ping databases from each other using tnsping , but iam not able to transfer archive logs from primary to standby
    pfile for primary is
    primary.__db_cache_size=67108864
    primary.__java_pool_size=4194304
    primary.__large_pool_size=4194304
    primary.__shared_pool_size=88080384
    primary.__streams_pool_size=0
    *.audit_file_dest='C:\oracle\product\10.2.0/admin/primary/adump'
    *.background_dump_dest='C:\oracle\product\10.2.0/admin/primary/bdump'
    *.compatible='10.2.0.1.0'
    *.control_files='C:\oracle\product\10.2.0\oradata\primary\control01.ctl','C:\oracle\product\10.2.0\oradata\primary\control02.ctl','C:\oracle\product\10.2.0\oradata\primary\control03.ctl'
    *.core_dump_dest='C:\oracle\product\10.2.0/admin/primary/cdump'
    *.db_block_size=8192
    *.db_domain=''
    *.db_file_multiblock_read_count=16
    *.db_name='primary'
    *.dispatchers='(PROTOCOL=TCP) (SERVICE=primaryXDB)'
    *.job_queue_processes=10
    *.log_archive_dest_2='SERVICE=stby'
    *.log_archive_dest_state_2=ENABLE
    *.open_cursors=300
    *.pga_aggregate_target=16777216
    *.processes=150
    *.remote_login_passwordfile='EXCLUSIVE'
    *.sga_target=167772160
    *.undo_management='AUTO'
    *.undo_tablespace='UNDOTBS1'
    *.user_dump_dest='C:\oracle\product\10.2.0/admin/primary/udump'
    log_archive_dest_1='LOCATION=C:\oracle\product\10.2.0\db_1\database\archive'
    log_archive_dest_state_1=ENABLE
    LOG_ARCHIVE_CONFIG='DG_CONFIG=(primary,stby)'
    pfile from standby
    primary.__db_cache_size=75497472
    primary.__java_pool_size=4194304
    primary.__large_pool_size=4194304
    primary.__shared_pool_size=79691776
    primary.__streams_pool_size=0
    *.audit_file_dest='C:\oracle\product\10.2.0\admin\adump'
    *.background_dump_dest='C:\oracle\product\10.2.0\admin\bdump'
    *.compatible='10.2.0.1.0'
    *.control_files='C:\oracle\product\10.2.0\oradata\stby.ctl'
    *.core_dump_dest='C:\oracle\product\10.2.0\admin\cdump'
    *.db_block_size=8192
    *.db_domain=''
    *.db_file_multiblock_read_count=16
    *.db_name='primary'
    db_unique_name='stby'
    *.dispatchers='(PROTOCOL=TCP) (SERVICE=primaryXDB)'
    *.job_queue_processes=10
    *.open_cursors=300
    *.pga_aggregate_target=16777216
    *.processes=150
    *.remote_login_passwordfile='EXCLUSIVE'
    *.sga_target=167772160
    *.undo_management='AUTO'
    *.undo_tablespace='UNDOTBS1'
    *.user_dump_dest='C:\oracle\product\10.2.0\admin\udump'
    standby_archive_dest='C:\oracle\product\10.2.0\stbyarch'
    db_file_name_convert='C:\oracle\product\10.2.0\oradata\primary','C:\oracle\product\10.2.0\oradata'
    log_file_name_convert='C:\oracle\product\10.2.0\oradata\primary','C:\oracle\product\10.2.0\oradata'
    standby_file_management=AUTO

    You do not point to the standby database from your primary, in order to get the archivelogs transfered. You need to set at least the parameter LOG_ARCHIVE_DEST_2 like this:
    SQL>alter system set LOG_ARCHIVE_DEST_2='SERVICE=stdby VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=stdby';stdby has to be resolved by the tnsnames.ora on the primary server. Have a look here:
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14239/create_ps.htm#i67520
    That explains all you need to do to create a physical standby briefly.
    Kind regards
    Uwe
    http://uhesse.wordpress.com

  • How to backup the archived log after a crosscheck .

    Hi all,
    Here is the scenario:
    My archive area got full, I moved some archived logs to another destination. My main script to backup archive log raised a error informing that some files were missing, so I issued a crosscheck archivelog all command.
    I realized that I did something insane and is there any way to fix it? I mean, how could I backup the missed sequence? Because I'll need to send them to a tape and also register the files in the RMAN's catalog.
    Regards and thanks in advance,
    Emerson

    user11983913 wrote:
    Hi all,
    Here is the scenario:
    My archive area got full, I moved some archived logs to another destination. My main script to backup archive log raised a error informing that some files were missing, so I issued a crosscheck archivelog all command.
    I realized that I did something insane and is there any way to fix it? I mean, how could I backup the missed sequence? Because I'll need to send them to a tape and also register the files in the RMAN's catalog.
    Regards and thanks in advance,
    EmersonHi Emerson
    Use the following command to register moved archived redo logs to RMAN repository
    CATALOG ARCHIVELOG '';

  • Question about only new archive logs backed up in backup

    Hi,
    We are taking daily two online backup. We are running database in ARCHIVELOG mode. We configure database in PRIMARY and PHYSICAL STANDBY mode. Till now, we were taking all archive logs in backup. But it was causing problem of lot of space utilization of disk.
    So based on search in this forum, I am planning to take only new archive logs generated since last backed up using following command.
    BACKUP ARCHIVELOG all not backed up 1 times format '$dir/archivelogs_%s_%t' FORCE;
    I am not sure about how it impact during restore and recovery when we take only new archivelogs in backup.
    We restore database and then after perform always incomplete recovery till latest SCN capture in backup using following commands.
    RESTORE DATABASE;
    RECOVER DATABASE UNTIL SCN $BACKUP_LAST_SCN;
    Do you see any problem/risk of implementing this solution going ahead?
    Please let me provide your thoughts/inputs for this.
    Thanks.
    Shardul

    Hi,
    We are not deleting archive logs from actual location after backup. We keep latest 6 days archive logs at actual location. But here we are planning to put only new archive logs in backup image which were not backed up due to disk size problem.
    For your reference below is our datbase backup RMAN commands. We are taking full database backup.
    run {
    ALLOCATE CHANNEL C1 TYPE DISK;
    delete noprompt archivelog all completed before 'sysdate-5';
    SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    BACKUP INCREMENTAL LEVEL=0 CUMULATIVE format '$dir/level0_%u' DATABASE include current controlfile
    for standby force;
    SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    BACKUP ARCHIVELOG all not backed up 1 times format '$dir/archivelogs_%s_%t' FORCE;
    BACKUP CURRENT CONTROLFILE format '$dir/control_primary' FORCE;
    Then in this polich do you see any problem when we restore database as PRIMARY or PHYSICAL STANDBY on server. We are using Oracle 10.2.0.3.

  • Too many archived logs when trying a backup

    Hello all,
    I'm having a bit of trouble running a backup script on an Oracle instance (10g1, on Solaris).
    As a normal DBA practice, I guess the backup should be scheduled and run from the very beginning of using a DB. Sometimes, from various reasons, this does not happen. In this case, before running the first (full) backup of the DB, there might be tens or hundreds of archived logs waiting to be backed up, and the flash recovery area might just not be able to handle all of them (at least that's how I see it, I might be wrong, I'm still fighting my way through Oracle's Backup and Recovery issues). In that case, a backup script containing the following RMAN sequence:
    run{
    allocate channel ch1 type disk;
    backup
    incremental
    level = 0
    database;
    release channel ch1;
    fails with the error message ORA-19804 (cannot reclaim disk space from the DB_RECOVERY_FILE_DEST_SIZE limit).
    After this, the archived logs that were backed up are marked as obsolete, and I can delete them from RMAN with "delete obsolete". The script I'm using for backup runs fine afterwards. Before attempting a backup, however, no logs are reported as obsolete.
    The retention policy is the default "redundancy 1" and the archivelog deletion policy is none.
    How could I prevent the backup script from crashing? If I'm changing the archivelog deletion policy, will I be able to restore the DB properly from my backup set? (as earlier logs will be deleted before making a backup)
    Thank you for any suggestions, your help is very much appreciated,
    Adrian

    I am having an impression that you are not using scheduled backups and let client decided when to take backup. Well this is not good, in this case you won't be able to get rid of this error bcz you never know when the next or even first backup is going to occur and without that you can't even think of deleting your logs. If you are not using tape drives then your archivelogs and backups both will sit in recovery area and you should have enough available space to hold both of them. I would say to schedule your backups and use DELETE INPUT clause of RMAN backup to delete the archivelogs after backing them up. And also delete the obsolete backups according to your recovery window. This is the proper way to manage recovery area space. You really need to tune the recovery area space by testing the amount of redo generation, backup size, retention policy etc etc and then come up with a figure of recovery area size which is suitable for your env to hold all of the required files for required time (recover window).
    Daljit Singh

  • Best way of deleting archive logs on standby when backup taken on primary

    Hello,
    I have a 11gr2 dataguard configuration without the broker.
    main problem in my particular situation arises from my FRA size on primary much more than on standby (90Gb vs 30Gb) and in some situations I'm constrained with FRA space on standby.... I'm going to align the FRAs but in the mean time....
    can anyone confirm that if I have configuration as in subject with maximum performance mode and I'm not using the broker I should consider a sort of "external" way for archive log deletion on the physical standby?
    In fact I'm setting on primary
    - retention policy = redundancy 1
    - archivelog deletion = applied on standby (without using any "backed up...." option)
    Considering the standby it seems from docs that:
    - retention policy always wins over deletion policy (so no archive eligible for deletion is deleted if retention is not satisfied)
    - I can set on standby archivelog deletion = applied on standby (without using any "backed up...." option)
    But it is not clear to me the effect of this config in case this is a standby itself and without any other cascade standby databases
    The manual says this has to be met:
    1) The archived redo log files have been applied to the required standby databases.
    ---> what does this mean in case the db is a standby.. met or not met as I have no other cascade standby dependant on this one?
    2) The logs are not needed by the BACKED UP ... TIMES TO DEVICE TYPE deletion policy. If the BACKED UP policy is not set, then this condition is always met.
    ---> I should be ok
    So the last question for standby is
    - what to set retention policy to?
    I have not understood if I set it to "NONE", this means no retention at all or retention for ever....
    sometimes I read that there is no policy; in other examples that files will be retained forever (because no file considered as obsolete).... or at least so I understood...
    I would like to have a sort of policy on standby where the archive logs can be deleted as soon as they are applied during the continuous media recovery phase...
    It seems I can't find a self contained set of configurations across the dataguard....
    Thanks in advance.
    Gianluca

    I agree with you.... It is a temporary contingency....
    I already stressed the fact that sizes between sites must be quite identical...
    we are going towards a production dataguard, migrating from a windows config (without it) to a Linux based config....
    but this contingency made me think about these considerations regarding policies and automatic dataguard operations
    I also stressed on equal size grow capability for both sites file systems, also for data tablespaces, so that for example in case of high fragmentation we have to avoid a limit situation where
    1) a file system full for DR datafiles causes abend of automatic media recovery
    2) this generates FRA growth in DR because archive logs are shipped but not applied any more
    3) FRA goes 100% in DR and primary cannot ship any more
    4) archive logs cannot be automatically deleted on primary because not already shipped
    5) FRA full on primary and DB hangs....
    Thanks anyway for input

Maybe you are looking for