Flashback Rman question

We are running Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production. (Linux Red Hat AS 4)
Flashback is setup to use this folder /u01/app/oracle/flash_recovery_area/<DATABASE>
RMAN backups to:
/u01/app/oracle/flash_recovery_area/<DATABASE>/backupset
A Full RMAN backup is performed daily.
RMAN creates folders daily for the backup under /backupset, for example:
2010_06_17
2010_06_18
2010_06_19 (and so on)
The RMAN cleans up old backups by issuing this command:
DELETE noprompt BACKUP COMPLETED BEFORE 'SYSDATE-3' DEVICE TYPE DISK;
This leaves the old folder behind. I can clean these up using the OS but my question is:
"Is there a way to have RMAN clean them up when it deletes the Backup?"
Edited by: mseberg on Jun 21, 2010 2:37 PM

Hi,
You need to remove the folders yourself. RMAN will not remove them for you. Write a script to perform this action.
RMAN is not aware whether the folder is empty or has any contents, it is simply removing the backupsets.
Asif Momen
http://momendba.blogspot.com

Similar Messages

  • RMAN question

    Hi gurus;
    I am using one RMAN script for 9.2.0.8 db,its:
    rman target / <<EOF
    SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    DELETE NOPROMPT OBSOLETE;
    BACKUP DATABASE PLUS ARCHIVELOG ;
    crosscheck backup;
    crosscheck archivelog all;
    RMAN> show all;
    RMAN configuration parameters are:
    CONFIGURE RETENTION POLICY TO REDUNDANCY 1;
    CONFIGURE BACKUP OPTIMIZATION ON;
    CONFIGURE DEFAULT DEVICE TYPE TO DISK;
    CONFIGURE CONTROLFILE AUTOBACKUP ON;
    CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/xx/ctrl_%F';
    CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
    CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1;
    CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1;
    CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/xx/backup_db_s%s_p%p_%T' MAXPIECESIZE 3000 M;
    CONFIGURE MAXSETSIZE TO UNLIMITED; # default
    CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/xxx/snapcf_VIS.f';
    My question is i need one script (RMAN) for it will run in day 3 times and take backup of all arhive than it will delete exsiting archive in archive log destinaton, coz for archive destination i have disk size problem.
    Is anyone help me?

    aaaaa wrote:
    rman target / <<EOF
    SQL 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    DELETE NOPROMPT OBSOLETE;
    BACKUP DATABASE PLUS ARCHIVELOG ;
    crosscheck backup;
    crosscheck archivelog all;
    First of all, usually you would first do a crosscheck and then the DELETE
    I recommend to split up the tasks into two scripts. One for the nightly backup called "fbackup.cmd". The contents would look like:
    run {
    allocate channel ch1 type 'sbt_tape' parms '<your tape storage parameter>';
    backup
    incremental level 0
    format 'df_%d_t%t_s%s_p%p'
    (database include current controlfile);
    sql 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    }And one for the archivelogs only, that runs multiple time across the day called: "archbackup.cmd"
    run {
    allocate channel ch1 type 'sbt_tape' parms '<your tape storage parameters>';
    backup
    incremental level 0
    format 'arch_%d_t%t_s%s_p%p'
    (archivelog all delete input );
    sql 'ALTER SYSTEM ARCHIVE LOG CURRENT';
    }This way a crosscheck is not needed, because RMAN itself deletes the archives and updates the catalog.
    Both scripts can be called with the following command line:
    rman target / [rcvcat user/passwd@catalogdb] cmdfile [fbackup.cmd|archbackup.cmd]
    Hope this helps.
    FJFranken
    My Blog: http://managingoracle.blogspot.com

  • RMAN question(any option to bypass any internal RMAN errors)

    Hi All,
    Os : Solaris 10
    db : 10.2.0.4
    in rman backup script i have mentioned as below before firing backup
    CONFIGURE EXCLUDE FOR TABLESPACE 'ABC';
    CONFIGURE EXCLUDE FOR TABLESPACE 'DEVELOPER';
    CONFIGURE EXCLUDE FOR TABLESPACE 'BACKUP';
    CONFIGURE EXCLUDE FOR TABLESPACE 'REPORT';
    one of our dba has dropped one tablespace which is not imporatant (ABC)...
    same day when backup has fired from cron ..backup has got failed and thrown following error
    RMAN-20202: tablespace not found in the recovery catalog
    RMAN-06019: could not translate tablespace name "ABC"
    My question : is there any way to bypass any such errors (like in "imp" command IGNORE option)
    any such options available at RMAN level..?
    Thanks a lot
    Vamshi

    Hi;
    Please check below notes which could be helpful for your issue:
    Configure Exclude For Tablespace Fails With RMAN-03002 RMAN-20202 RMAN-06019 [ID 466474.1]
    Can you tell RMAN not to create a tempfile with duplicate or recovery with version 10.2? [ID 863197.1]
    RMAN Convert, returns error Rman-20202: Tablespace Not Found In The Recovery Catalog [ID 360580.1]
    Cannot Exclude Plugged-in TableSpace Rman-06019 [ID 313044.1]
    Regard
    Helios

  • RMAN questions

    New to Oracle DBA world. Some basic quetions, I will appreciate for help.
    what is the meaning of this
    restore database validate;
    is it good to include this in daily full backup script.
    My rman destination is sbt (tape). I want to copy some os files also on the tape with rman. what is the syntax to include that in the rman command 'host cp ----' ;.
    OS is sun solaris and databases are oracle 9i and 10g . thanks

    Check this for your restore validate question:
    http://download-east.oracle.com/docs/cd/B10501_01/server.920/a96565/rcmsynta46.htm#93304
    You CAN NOT take file system backups to tape using RMAN. Which Media Manager software are you using to take RMAN backups on tape?? If that MM provides you an interface to take OS filesystem backup then you have to use that (outside from RMAN). Like OSB provide you to take RMAN plus file system backup option. Check your media manager software for more details on this.
    Daljit Singh

  • Flashback Database question

    I have a question about the contents of flashback logs used in Flashback Database. Oracle documentation says Flashback Logs contain 'before images' of the blocks to undo changes to a point in time just before a specified target time or SCN. Does this make flashback logs similair to blocks in Undo Segments.
    Also, in some books notably one Oracle Press book for OCA (1z0-042) preparation written by Damir Bersinic, it is mentioned that flashback logs contain 'altered blocks' rather than "images of blocks before the change" mentioned in Oracle Docs. If it is 'altered blocks', then that would make flash logs similair to redo logs. which one is right?

    I would agree and go with Oracle Documentation (for obvious reasons..right!). Flashback logs contains 'before images"....and you are right then it would be similar to undo changes, but undo changes are not retained are preserved for whole lot of time right? so as to allow you to go to a point in time in the past. I am sure there would be differences in how the before images in flashback logs are stored than that of undo.
    Thanks
    Chandra Pabba

  • RMAN question concerning Physical Standby

    We have a database in a two-server Dataguard environment. We use RMAN to backup up the Primary database (on the server CORE), but we do not backup the Physical Standby (this was recommended by our vendor).
    Once a month, I switchover the Primary database (on the server CORE) over to the Physical Standby database (which is on the server DG). I apply Linux patches to the CORE server and reboot. I then bring up the database as Physical Standby (using "startup nomount", followed by "alter database mount standby database" and then "alter database recover managed standby database disconnect from session"), and then I do a switchover and make it the Primary again.
    My question is, after I bring up the database on the server CORE as a Physical Standby, and before I do a switchover to make it the Primary again, can I use RMAN to run a "restore database validate" to see if my backups are currently valid, or would this not give me the expected results since I am the Physical Standby?
    Thanks in advance.

    You should have any problem. What you're doing is similar to a a "rolling upgrade". When your physical to production environment make sure put the dest_2 in defer. Is your current physical standby works now? If so, there's problem.

  • A Rman question

    You issued the following commands to configure setting in RMAN;
    RMAN> CONFIGURE DEVICE TYPE sbt PARALLELISM 1;
    RMAN> CONFIGURE DEFAULT DEVICE TYPE TO sbt;
    RMAN> CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE sbt TO 2;
    RMAN> CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE sbt TO 2;
    RMAN> CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 2;
    Then you issued the following command to take the backup:
    RMAN> BACKUP DATABASE PLUS ARCHIVELOG;
    Which statement is true about the execution of the above command?
    A - The backup will terminate because the FORMAT clause was not configured for the channel
    B- It backs up two copies of data files to tape and disk, and two copies of archived log file on tape
    C- It backs up the data files and archived log files to disk, making two copies of each data file and archived log file
    D-It backs up the data files and archived log files to tape, making two copies of each data file and archived log file
    thx in adv

    Are you taking a test right now? ( Cause if you are this is a bad idea, google will bust you )
    Very odd question.
    # configures one sbt channels for use in RMAN jobs:
    RMAN> CONFIGURE DEVICE TYPE sbt PARALLELISM 1;
    RMAN> CONFIGURE DEFAULT DEVICE TYPE TO sbt;
    # Makes 2 disk copies of each datafile and control file to tape
    RMAN> CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE sbt TO 2;
    # Makes 2 copies of every archived redo log backup to tape
    CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE sbt TO 2;
    # Makes 2 disk copies of each datafile and control file backup set
    # (autobackups excluded)
    CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 2
    Best Regards
    mseberg

  • Hot Backup with RMAN question.

    Hi all.
    We want to make a full backup with RMAN every night with the db up. Version 9i in archive log mode.
    My question is if with the command:
    backup database plus archivelog delete input format 'MY_FORMAT_STRING';
    will store all the files needed for the recovery in one file or I need to backup some other file or do more actions. The backup will be consistent?
    Regards.

    By using this command you are only taking the backup
    all the database files plus all the archived logs
    needed for point on recovery.
    But still you will have to take the backup of Control
    file and parameter files. Which you do by configuringi think its not
    RMAN> configure controlfile autobackup off
    2> ;
    old RMAN configuration parameters:
    CONFIGURE CONTROLFILE AUTOBACKUP ON;
    new RMAN configuration parameters:
    CONFIGURE CONTROLFILE AUTOBACKUP OFF;
    new RMAN configuration parameters are successfully stored
    RMAN> backup database
    2> ;
    Starting backup at 28-NOV-07
    using channel ORA_DISK_1
    channel ORA_DISK_1: starting full datafile backupset
    channel ORA_DISK_1: specifying datafile(s) in backupset
    input datafile fno=00001 name=C:\ORACLE10G\ORACLE\ORADATA\ORCL\ORCL\SYSTEM01.DBF
    input datafile fno=00003 name=C:\ORACLE10G\ORACLE\ORADATA\ORCL\ORCL\SYSAUX01.DBF
    input datafile fno=00002 name=C:\ORACLE10G\ORACLE\ORADATA\ORCL\ORCL\UNDOTBS01.DB
    F
    input datafile fno=00004 name=C:\ORACLE10G\ORACLE\ORADATA\ORCL\ORCL\USERS01.DBF
    input datafile fno=00005 name=C:\ORACLE10G\ORACLE\ORADATA\ORCL\ORCL\DATA.DBF
    channel ORA_DISK_1: starting piece 1 at 28-NOV-07
    channel ORA_DISK_1: finished piece 1 at 28-NOV-07
    piece handle=C:\ORACLE\FLASH_RECOVERY_AREA\ORCL\ORCL\BACKUPSET\2007_11_28\O1_MF_
    NNNDF_TAG20071128T151313_3NTHSTK9_.BKP comment=NONE
    channel ORA_DISK_1: backup set complete, elapsed time: 00:00:45
    channel ORA_DISK_1: starting full datafile backupset
    channel ORA_DISK_1: specifying datafile(s) in backupset
    including current controlfile in backupset
    including current SPFILE in backupset
    channel ORA_DISK_1: starting piece 1 at 28-NOV-07
    channel ORA_DISK_1: finished piece 1 at 28-NOV-07
    piece handle=C:\ORACLE\FLASH_RECOVERY_AREA\ORCL\ORCL\BACKUPSET\2007_11_28\O1_MF_
    NCSNF_TAG20071128T151313_3NTHV8S5_.BKP comment=NONE
    channel ORA_DISK_1: backup set complete, elapsed time: 00:00:03
    Finished backup at 28-NOV-07
    RMAN>backup database backup controlfile as well spfile but its better backup control file separately after backing up the database plus archivelog cause a backup set info within control file which will not be in control file which is just backed up by backup database .
    Khurram
    null

  • Remedial rman question - how to connect to db

    Hi.
    I need to start making some tests with rman, with the hope of maybe next year presenting it as an option for our data managment here.
    First, I need to connect to my test database, but Im already having some problems:
    I am following the documentation (version 9.2) "Connecting to Databases with rman".
    Chapter 2 explains:to start rman do this :
    rman TARGET SYS / oracle@trgt NOCATALOG
    I dont want to use a catalog. I have been reading the rman concepts for weeks and Im quite happy with them. Just having practical probs!
    Any help please?
    Cheers.
    DA

    Werner:
    I checked in Computer Management and I am a member of ORA_DBA
    I changed the setting in sqlnet as instructed, now I am trying it this way:
    C:\>rman target sys/password@net_service_name
    And this is the subsequent result:
    Recovery Manager: Release 9.2.0.1.0 - Production
    Copyright (c) 1995, 2002, Oracle Corporation. All rights reserved.
    error occurred in source file: krmk.pc, line: 22659
    text of failing SQL statement: declare vsn varchar2 ( 20 ) ; begin vsn := dbms_r
    cvman . getPackageVersion ; :pkg_vsn:pkg_vsn_i := vsn ; if vsn is not null then
    :pkg_vsnub4 := to_number ( substr ( vsn , 1 , 2 ) || substr ( vsn , 4 , 2 ) || s
    ubstr ( vsn , 7 , 2 ) ) ; end if ; end ;
    ORACLE error from target database:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-00376: file 2 cannot be read at this time
    ORA-01110: data file 2: 'C:\ORACLE\ORADATA\DAVID\UNDOTBS01.DBF'
    ORA-06508: PL/SQL: could not find program unit being called
    ORA-06512: at line 1
    error executing package DBMS_RCVMAN in TARGET database
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-00554: initialization of internal recovery manager package failed
    RMAN-06429: TARGET database is not compatible with this version of RMAN
    "Not compatible" ???
    Any ideas ???
    Thanks.
    DA
    Message was edited by:
    Dan A

  • Advance RMAN Question

    what is difference b/w backupset and image copy?
    what is multiplexing?
    what is parallelism?
    What are common problems faced with media manager? any common issues with RMAN?
    How we can update rman repository?
    if we dont need backups in rman anymore what to do with Recovery catalog to update?
    Difference b/w list and reprot ?

    what is difference b/w backupset and image copy?backupsets are black box files that only rman can restore. Image copies
    are as is copied of the datafiles in your database
    what is multiplexing?Sending backups to multiple destinations
    what is parallelism?Allowing mulriple rman processes to perform the backup or restore
    What are common problems faced with media manager?non-trivial answer - see links posted
    any common issues with RMAN?non-trivial answer - see links posted
    How we can update rman repository?non-trivial answer - see links posted
    >
    if we dont need backups in rman anymore what to do
    with Recovery catalog to update?set retention policy
    >
    Difference b/w list and reprot ?

  • Basic rman question

    can we take physical backup from the remote location....

    I know nothing about solaris, but samba could be a solution. Isn't it possible to activate the samba service at the server side? It could be useful for other services too, if needed, and it won't consume much ressources.
    We work with linux and nfs is our option with rman. However, samba would be our second option, and I think it's your first one ;)

  • Basic flashback config question

    I have an Oracle database (10.2.0.4.0 on Linux) installation that I have inherited. A user deleted some data and I attempted to recover it. There were backups and archive log files in the FRA, but when I queried about flashback status I got:
    select flashback_on from v$database;
    FLASHBACK_ON
    NO         
    1 row selected (0.06 seconds)With that config set to "no" that means I can not use flashback to recover lost data. It must be set to yes before the failure occurs in order to use flashback to recover afterwards. Do I have that right?

    I have an Oracle database (10.2.0.4.0 on Linux) installation that I have inherited. A user deleted some data and I attempted to recover it. There were backups and archive log files in the FRA, but when I queried about flashback status I got:
    With that config set to "no" that means I can not use flashback to recover lost data. It must be set to yes before the failure occurs in order to use flashback to recover afterwards. Do I have that right?Are you sure that you have committed the deleted data, if not you can rollback.
    If your retention is not enough big, however you disabled FLASHBACK, you cant get it.
    But there is a big procedure, if it is really critical, if your database is running in archivelog mode, Restore database in any test server, recover database before deleting rows, Take an export of the table and import into this database.
    Edited by: CKPT on Jun 20, 2011 7:15 PM

  • RETENTION POLICY in RMAN question

    Is a good practice to set up a RETENTION POLICY for the full backups (level 0) and another RETENTION POLICY for the incremental backups (level 1)? If yes, why and how could I do this ?
    Thanks for your responses,
    Christine.

    It is from the doc
    http://download.oracle.com/docs/cd/B19306_01/backup.102/b14191/rcmconc1007.htm#sthref279
    From the perspective of a retention policy, a datafile backup is a full or level 0 backup of an individual datafile or control file. It does not matter whether the backup is a datafile image copy, a proxy copy, or part of a backup set. For datafile copies and proxy copies, if RMAN determines that the copy or proxy copy is not needed, then the copy or proxy copy can be deleted. For datafile backups in backup sets, RMAN cannot delete the backup set until all of the individual datafile backups within the backup set are obsolete.
    Besides affecting full or level 0 datafile and control file backups, the retention policy affects archived redo logs and level 1 incremental backups. First, RMAN decides which datafile and control file backups are obsolete. Then, RMAN considers as obsolete all archived logs and incremental level 1 backups that are not needed to recover the oldest datafile or control file backup that must be retained.

  • Simple RMAN question

    Hi,
    Is there a way to run command line sqlplus commands from the rman command line. I'm sure I saw someone doing it once. Just to save time jumping between RMAN and sqlplus all the time
    Many thanks
    FLaz

    Please,
    Always include platform and version (4 digits).
    Also, please, as this forum is manned by volunteers, try to read the docs prior to posting, as instructed by the Forums Etiquette post.
    This is a forum, and not a chatroom.
    In this case you could simply have read up on the RMAN sql command.
    Sybrand Bakker
    Senior Oracle DBA

  • ORACLE RMAN QUESTION

    Hi,
    We take daily incremental backup and weekly full backup.
    Our retention policy is 15 days.
    Now I want to store my end of month backup seperately so that I can use it later.
    How can I achive this with rman.
    Thanks in advance.

    the CHANGE KEEP just say you want to keep a backup piece. It does not mean you can do anything with that piece!!!
    You must make sure you keep enough backups and archivelogs to restore and recover your database successfully! So in incremental, you need to mark the full for KEEP + the incremental + the latest archivelog...
    Be sure you test it yourself, backup is serious, do not rely on my procedure without testing it regularly! Thanks

Maybe you are looking for

  • Validation for accounting document during MIGO

    Hello experts, I would like to force the user to choose document type: FR while trying to post a credit memo via MIGO. How can I do it ? Thanks a lot.

  • Po text mandatory

    Hi All,      How to make some of PO text fields mandatory.In configuration i made PO text indicator as required field .After that while creating P O in ME21N all the fields are becoming display mode Pls Guide me how to solve this Issue. Regards vr

  • Self-Destructive .swf

    Hey i want to ask you can i create the following thing and if i can do you have any ideas how. I want to create a simple .swf where for example on frame 1 i have a photo. And what i want is after you open the .swf you will have about 10 seconds to vi

  • Cursor as an IN Parameter

    Hello, I want to know if is possible to have (and the way to do it) a Cursor as an IN parameter. For example to have a cursor for insert some of its fields in a table. I have tried using a REF CURSOR in a package but it only works for returning a cur

  • Why can't I just click on a tab to open it anymore? I hate this new version!

    I used to be able to just click on a tab to open it. now I have to go to this stupid drop down menu to choose which tab I want to go to. This absolutely sucks!!! if this problem isn't taken care of soon, I'm switching to opera!