Obsolete backup
Hello all,
I am using Oracle 11g R2.
on RMAN i wanted to report the obsolete backup and the below result appear, but i am not able to analyze it:
RMAN> report obsolete
2> ;
RMAN retention policy will be applied to the command
RMAN retention policy is set to redundancy 1
Report of obsolete backups and copies
Type Key Completion Time Filename/Handle
Backup Set 252 11-SEP-11
Backup Piece 452 11-SEP-11 C:\APP\ORACLE\FLASH_RECOVERY_AREA\WINDB\AUTOBACKUP\2011_09_11\O1_MF_S_761565747_76RTRRNP_.BKP
Backup Set 254 11-SEP-11
Backup Piece 454 11-SEP-11 C:\APP\ORACLE\FLASH_RECOVERY_AREA\WINDB\AUTOBACKUP\2011_09_11\O1_MF_S_761565802_76RTTFF2_.BKPwhat i understood that key= 452 and key = 454 are obsolete. but what are the 252 and the 254 ?
what the key is for ? is that logged in any table/view?
Regards,
Hello,
A backup set is a logical structure created by RMAN when you lanuch a backup. A backup set can contain one or more backup pieces, which are the binary files you can see at OS level. In your case, each backup set contains only one backup piece.
The backup sets 252 and 254 are obsolete, which means that the backup pieces inside, 452 and 454 are obsolete too.
The key is the identifier of backup sets and backup pieces.
Here is the explanation of backup pieces and backup sets :
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10642/rcmcncpt.htm#BRADV106
And the explanation of the informations given by the LIST command, that can be helpful for understanding your output :
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10643/rcmsynta027.htm#sthref1173
And the list of recovery catalog views :
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10643/rcviews.htm#RCMRF003
Hope this will help.
Regards,
Sylvie
Similar Messages
-
RMAN Recovery Window 7 days setting - shows no obsolete backups
Hi All. Quick question about RMAN retention policy....
I have the current backup strategy:
Full backup (0) -> Sunday
Incremental backup (1) -> Monday - Saturday
Archive log backups -> every hour
This is a new database I just started taking backups on last month. (1st full backup was run October 4th)
I currently have not deleted any of them.
The old RMAN RETENTION POLICY was set to REDUNDANCY = 1
REPORT OBSOLETE lists all of them up to the last full which ran this past Sunday (Nov 1st)
I just switched the RMAN RETENTION POLICY to RECOVERY WINDOW of 7 DAYS
REPORT OBSOLETE lists no backups obsolete...
Shouldn't I see all the backups prior to a week ago or does it only take affect for backups run under the new policy?
Any help/replies are apprecitaed.
ThanksRan crosscheck with no problems:
Crosschecked 200 objects
But still same results for:
RMAN> report obsolete;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 7 days
no obsolete backups found
Am I missing something here? Or like I mentioned is this expected behaviour because all of my other backups were run with REDUNDANCY = 1 retention policy?
Thanks -
How to list all obsolete backuped archivelog
today I backup the whole database(this is the
first time I backup the database) with command
" backup database",and alse backup all
archivelog,and the oldest archivelog is three days
ago,and after the backup,I want to report obsolete
backup,but using
"report obsolete until time 'SYSDATE-1'"
command get a output of nothing,and IMO because I
backup the whole database,at least the archivelogs
before yesterday are not usefull for restore,and
it should be obsolete.When I read rman reference,it
sames that obsolete only apply to datafile,but no
archivedlog.You are right, in the 8i doc, it contains an "until" clause and does not list obsolete archive logs.
http://download-uk.oracle.com/docs/cd/A87860_01/doc/server.817/a76990/rmansy35.htm#23596
You should then try to write your own script in sqlplus.
Example, which delete all backups of archive logs older then yesterday.
$ sqlplus rman/rman@RMANREP
SQL> select db_name, max(THREAD#), max(SEQUENCE#) from rc_backup_redolog where completion_time < sysdate-1 group by db_name;
DB_NAME MAX(THREAD#) MAX(SEQUENCE#)
PROD 1 133
$ rman sys/change_on_install@PROD rman/rman@RMANREP
RMAN> delete noprompt archivelog until sequence 133 thread 1; -
Hi,
In my 10gR2 database, level1 backup is taken every nigh except sunday, retention policy is set to redundancy 1.
but rman not considering previous backup as obsolete.
below is level1 backup script.
{color:#0000ff}cp $ORACLE_HOME/dbs/orapworampls /backup/RMANBACKUP/orapworampls_backup
# start the rman backup
# only use the next line if this script needs run via root CRON
#su - $ORACLE_OWNER -c "$ORACLE_HOME/bin/rman 'target /'"<< EOF
$ORACLE_HOME/bin/rman 'target /' catalog rman/rman@rman<< EOF
configure retention policy to redundancy 1;
resync catalog;
configure backup optimization on;
configure controlfile autobackup on;
configure default device type to Disk;
configure device type Disk parallelism 2;
configure channel device type Disk format '/backup/RMANBACKUP/%d_LEVEL1_DATAFILE_%s_%p_%D_%M_%Y.bak';
configure maxsetsize to unlimited;
configure snapshot controlfile name to '/backup/RMANBACKUP/ORAMPLS_SNAPCF.f';
set controlfile autobackup format for device type Disk to '/backup/RMANBACKUP/ORAMPLS_CONTROLFILE_%F';
show all;
run {
allocate channel ch1 type Disk maxpiecesize = 1024M;
allocate channel ch2 type Disk maxpiecesize = 1024M;
backup
format '/backup/RMANBACKUP/ORAMPLS_CONTROLFILE_%u_%p_%c' (current controlfile);
backup
incremental level 1
tag 'ORAMPLS_DATAFILE_LEVEL_1'
format '/backup/RMANBACKUP/%d_LEVEL1_DATAFILE_%s_%p_%D_%M_%Y.bak' (database);
release channel ch1;
release channel ch2;
run {
delete noprompt backup of archivelog all completed before 'sysdate - 1';
run {
allocate channel ch1 type Disk maxpiecesize = 1024M;
allocate channel ch2 type Disk maxpiecesize = 1024M;
backup archivelog all
delete all input
format '/backup/RMANBACKUP/%d_ARCHIVELOG_%s_%p_%D_%M_%Y.bak'
tag 'ORAMPLS_ARCHIVELOG_FULL';
release channel ch1;
release channel ch2;
delete noprompt obsolete;
list backup of database;
quit
{color}{color:#000000}id i manually take backup of any datafile twice, its obsoleting older one.
{color}Retention policy will not affect incremental level 1 backups directly ,it will become obsoleted when its full backups obsoleted ,backup retention policy directly affect only full,level 0 and controlfile backups,archivlelog as well level 1 backup retention policy will affect indirectly.
For detail read that link i have created some sample cases over here within this threads debate
Re: About RMAN backup !!!!
Khurram -
Is it possible to restore DB from Obsolete backup?
Hi,
Is it possible to restore DB from Obsolete backup? If yes. How?
Thanks
RajeshCatalog your backup again to restore it. Please read the below paragraph.
Cataloging Older Files in the Recovery Catalog
If you have datafile copies, backup pieces or archive logs on disk, you can catalog them in the recovery catalog using the CATALOG command. When using a recovery catalog, cataloging older backups that have aged out of the control file lets RMAN use the older backups during restore operations. For example:
RMAN> CATALOG DATAFILECOPY '/disk1/old_datafiles/01_01_2003/users01.dbf';
RMAN> CATALOG ARCHIVELOG '/disk1/arch_logs/archive1_731.dbf',
'/disk1/arch_logs/archive1_732.dbf';
RMAN> CATALOG BACKUPPIECE '/disk1/backups/backup_820.bkp';
You can also catalog multiple backup files in a directory at once, using the CATALOG START WITH command, as shown in this example:
RMAN> CATALOG START WITH '/disk1/backups/';
RMAN lists the files to be added to the RMAN repository and prompts for confirmation before adding the backups.
Be careful when creating your prefix for CATALOG START WITH. RMAN scans all paths for all files on disk which begin with your specified prefix. The wrong prefix may include more files than you intend. For example, a group of directories /disk1/backups , /disk1/backups-year2003, /disk1/backupsets, and /disk1/backupsets/test and so on, all contain backup files. The command
RMAN> CATALOG START WITH '/disk1/backups';
catalogs all files in all of these directories, because /disk1/backups is a prefix for the paths for all of these directories. In order to catalog only backups in the /disk1/backups directory, the correct command would be:
RMAN> CATALOG START WITH '/disk1/backups/';
Regards
Asif Kabir -
When is delete all obsolete backups triggered in Oracle 11g DB
I have a query as to when delete all obsolete backups triggered in Oracle 11g DB. We changed the RMAN retention policy to 10 days from 14 days in our setup. Is it triggered manually by delete all obsolete from Availablity->Manage Current Backups in OEM or is it triggered automatically every time RMAN backup is done?
I hope, my question is clear.
Please revert with the reply to my query.
Regards975148 wrote:
I have a query as to when delete all obsolete backups triggered in Oracle 11g DB. We changed the RMAN retention policy to 10 days from 14 days in our setup. Is it triggered manually by delete all obsolete from Availablity->Manage Current Backups in OEM or is it triggered automatically every time RMAN backup is done?
I hope, my question is clear.
Please revert with the reply to my query.
Regards
First, I would never manage my backups in OEM. When the crunch comes at 2:00 am, I don't want ever more moving parts to be involved in recovery.
Second, the only thing approaching a "triggering" of deletion of backups is if your backups are in the FRA ... rman will, at the time of making a backup .. attempt to delete obsolete backups if necessary to free up space in the FRA.
Other than that, oboslete backups are only deleted in response to a direct DELETE OBSOLETE command. This command may optionally ( as shown by TigerDBA) include a run-time obsolesence rule, or it may depend on the standing configuration.
Another thing to note is that backups are NOT marked as obsolete. They are EVALUATED for obsolescence in response to a DELETE OBSOLETE or REPORT OBSOLETE command.
And one final thing to not is that all recovery must begin with a full backup. That would be the most recent full (or level 0 incremental) backup prior to the point in time to which you need to recover. That means the most recent full (or level 0 incremental) backup will never be considered obsolete, regardless of how old it is. -
Can we Restore a db from an obsolete backup ?
Hi everyone
I planned a database to have the recovery window of 7 days as retention policy.
What i want to ask is:
I didn't delete any obsolete backup
Is it possible for me to restore the database before the recovery windows
of 7 days , for example to 10 days before today ???
Thanx in advancewhats is the version of the database. Check the below post
Re: Recovering database from an obsolete backup -
RMAN fails to delete obsolete backup in OSB
Hi All,
I am trying to delete my obsolete backups through RMAN and I get this error:
ORA-19511: Error received from media manager layer, error text:
sbt__rpc_cat_delete: delete failed for piece 0hmlsu6q_1_2 (Oracle Secure Backup error: user does not have sufficient rights)
I am not clear why Oracle Secure backup throws error that the user does not have sufficient rights./.
Below are the commands that I am using in the script:
3> ALLOCATE CHANNEL TAPE01 DEVICE TYPE SBT_TAPE;
4> CROSSCHECK BACKUP;
5> CROSSCHECK ARCHIVELOG ALL;
6> CROSSCHECK COPY;
7> report obsolete recovery window of 60 days device type
8> report obsolete recovery window of 7 days device type disk
9> delete noprompt obsolete recovery window of 60 days device type SBT_TAPE;
10> delete noprompt obsolete recovery window of 7 days device type DISK;
Any help is appreciated..
Thanks..In my case, the problem was on OSB user permition.
On user you have to preauth. admin users to the host where database is located.
regards..
Virgilio -
Rman optimization conflicting with obsolete backups?
Hello,
Suppose I have the following configuration.
I have a partitioned table with each (month-)partition on a different tablespace. I need to keep 10yrs of data. Switch a tablespace with e.g. April2008 data to read-only.
Rman set REDUNDANCY 1 and OPTIMIZATION ON.
Now redundancy 1 should keep only 1 backup of each file wouldn't it?
I do a backup database: it backups every file.
I do a backup database again: it backups every file again.
I do a backup database third time: it says "skipping file n allready backed up 2 times".
Now I do a report obsolete: it marks one of the backups op my file with April2008 data as obsolete.
After performing a delete obsolete, it is gone.
Next day I do a backup database: it backups every file again, so I have two!! backups of file n.
I would like to have only 1 and just 1 backup of the file, and it should never be backed up anymore. The redundancy cannot be set to zero.
How to deal with this?I think we disagree on this. I can make a single-partition rman backup if:
It is on it's own tablespace, on it's own datafile. No problem with that. It is only the redundancy-problem I have.
Even if I configure redundancy to 1, it makes two backups, and one of these is obsolete. This obsolete gets deleted in a 'delete obsolete' action, and a new obsolete will be created with the next backup.
How would you backup the database with 120 partitions as I described above? Each day a full backup?? -
Hi
Monday (full db backup including controlfile).
Tuesday (full db backup including controlfile).
Wednesday (full db backup including controlfile).
Monday`s backup becomes obsolete after Wednesday backup completes and deleted from disk.
Suppose Monday`s backup has become obsolete and deleted from disk. I want to restore Monday`s backup.
If I put Monday`s backup back to disk, can I still restore it using current controlfile (Wednesday`s) ?
or
do I need to restore Monday`s controlfile first ?
or
should I catalog Monday`s backupset and start restore ?re,
you need to catalog the backup and set the until parameter.
You need to use an until time parameter or SCN before the backup finish otherwise you need additional
archivelogs..
*T -
Report obsolete returns diff results when backups are UNAVAIL vs AVAIL
Hello from Nova Scotia, Canada:
I'm wondering if someone out there who lives and breaths rman (10gR2) for a living can shed some light...
We are finding that report obsolete (as well as delete obsolete) are returning different results depending on if our backups
are AVAILABLE or UNAVAILABLE.
In our shop, our backups are changed to UNAVAILABLE because they get moved to a different location later, but delete
obsolete doesn't seem to work as expected unless the backups are AVAILABLE.
I am pasting some output below to demonstrate my point. Basically, in the output you are about to see, I'm showing you
my retention policy and I'm listing the backups that I have (and you can see their status is "A" for available). Then I do a
'report obsolete' command to show you what is considered obsolete (3 files are - which is what I expected). Then I change
all my backups to unavailable. Then I list all my backups again and show you that their status has changed to "U" for unavailable.
Then I do 'report obsolete' again and as you can see, I get different results! Can someone explain this to me?? I have RTFManuals
and no where does it say that availability is a factor that can impact determining what is obsolete. You also see in the output
below what version we're using (10.2.0.4.0) and that we are using a recovery catalog.
If someone would like to see additional information, feel free to ask, I'm more than happy to help you help me.
I should also mention this is a 2 node rac on linux.
Many Thanks.
========================================================
$ rman target / catalog rrc/rg@RRC
Recovery Manager: Release 10.2.0.4.0 - Production on Tue May 11 22:06:21 2010
Copyright (c) 1982, 2007, Oracle. All rights reserved.
connected to target database: IPCSD (DBID=1703825384)
connected to recovery catalog database
RMAN> show retention policy;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 1 DAYS;
RMAN> list backup summary;
List of Backups
===============
Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
64093 B F A DISK 05/10/2010 03:06:52 2 1 NO HOTBKUP201005100300_DB
64122 B A A DISK 05/10/2010 03:08:41 1 1 NO HOTBKUP201005100300_ARCHLOGS
64361 B F A DISK 05/10/2010 21:56:33 2 1 NO HOTBKUP201005102149_DB
64362 B F A DISK 05/10/2010 21:56:37 1 1 NO HOTBKUP201005102149_DB
64390 B A A DISK 05/10/2010 21:58:02 1 1 NO HOTBKUP201005102149_ARCHLOGS
64508 B F A DISK 05/11/2010 03:07:01 2 1 NO HOTBKUP201005110300_DB
64509 B F A DISK 05/11/2010 03:07:10 1 1 NO HOTBKUP201005110300_DB
64544 B A A DISK 05/11/2010 03:07:47 1 1 NO HOTBKUP201005110300_ARCHLOGS
RMAN> report obsolete;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 1 days
Report of obsolete backups and copies
Type Key Completion Time Filename/Handle
Backup Set 64093 05/10/2010 03:06:51
Backup Piece 64097 05/10/2010 03:06:51 /oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1349_PC_2_CP_1_DB
Backup Set 64093 05/10/2010 03:04:01
Backup Piece 64096 05/10/2010 03:04:01 /oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1349_PC_1_CP_1_DB
Backup Set 64122 05/10/2010 03:08:41
Backup Piece 64125 05/10/2010 03:08:41 /oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1351_PC_1_CP_1_ARCHLOGS
RMAN> change backup unavailable;
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1349_PC_1_CP_1_DB recid=1533 stamp=718599624
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1349_PC_2_CP_1_DB recid=1534 stamp=718599846
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005100300/RMAN_HOTBKUP_IPCSD_201005100300_BS_1351_PC_1_CP_1_ARCHLOGS recid=1536 stamp=718600043
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1354_PC_1_CP_1_DB recid=1539 stamp=718667376
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1354_PC_2_CP_1_DB recid=1540 stamp=718667600
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1355_PC_1_CP_1_DB recid=1541 stamp=718667797
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1356_PC_1_CP_1_ARCHLOGS recid=1542 stamp=718667821
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005110300/RMAN_HOTBKUP_IPCSD_201005110300_BS_1357_PC_1_CP_1_DB recid=1543 stamp=718686020
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005110300/RMAN_HOTBKUP_IPCSD_201005110300_BS_1357_PC_2_CP_1_DB recid=1544 stamp=718686253
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005110300/RMAN_HOTBKUP_IPCSD_201005110300_BS_1358_PC_1_CP_1_DB recid=1545 stamp=718686430
changed backup piece unavailable
backup piece handle=/oracle_admin/rman_backups/201005110300/RMAN_HOTBKUP_IPCSD_201005110300_BS_1359_PC_1_CP_1_ARCHLOGS recid=1546 stamp=718686452
Changed 11 objects to UNAVAILABLE status
RMAN> list backup summary;
List of Backups
===============
Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
64093 B F U DISK 05/10/2010 03:06:52 2 1 NO HOTBKUP201005100300_DB
64122 B A U DISK 05/10/2010 03:08:41 1 1 NO HOTBKUP201005100300_ARCHLOGS
64361 B F U DISK 05/10/2010 21:56:33 2 1 NO HOTBKUP201005102149_DB
64362 B F U DISK 05/10/2010 21:56:37 1 1 NO HOTBKUP201005102149_DB
64390 B A U DISK 05/10/2010 21:58:02 1 1 NO HOTBKUP201005102149_ARCHLOGS
64508 B F U DISK 05/11/2010 03:07:01 2 1 NO HOTBKUP201005110300_DB
64509 B F U DISK 05/11/2010 03:07:10 1 1 NO HOTBKUP201005110300_DB
64544 B A U DISK 05/11/2010 03:07:47 1 1 NO HOTBKUP201005110300_ARCHLOGS
RMAN> report obsolete;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 1 days
Report of obsolete backups and copies
Type Key Completion Time Filename/Handle
Backup Set 64362 05/10/2010 21:56:37
Backup Piece 64366 05/10/2010 21:56:37 /oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1355_PC_1_CP_1_DB
RMAN>I just want to point out that the one obsolete file just contains a Control File and a SPFILE, as shown below:
BS Key Type LV Size Device Type Elapsed Time Completion Time
64362 Full 17.64M DISK 00:00:02 05/10/2010 21:56:37
BP Key: 64366 Status: UNAVAILABLE Compressed: NO Tag: HOTBKUP201005102149_DB
Piece Name: /oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1355_PC_1_CP_1_DB
Control File Included: Ckp SCN: 15213106404 Ckp time: 05/10/2010 21:56:35
SPFILE Included: Modification time: 05/09/2010 18:00:42---------------
**** END *****
Edited by: user478914 on May 12, 2010 3:03 AM
Edited by: user478914 on May 12, 2010 3:24 AMThanks for reading my post. Here is the result of doing the crosscheck command.
Problem still exists. Someone correct me if I'm wrong but I believe crosscheck does
nothing because all my backups are listed as unavailable, so there is nothing for it to do.
Any other thoughts or suggestions?
This problem is driving me bonkers. I have read the Backup and Recovery Basic Guide and Advanced Guide,
googled the web, searched OTN, searched Metalink and I can't find anything on the topic of backup
piece availability affecting obsolescence. Many thanks.
RMAN> list backup summary;
List of Backups
===============
Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
64361 B F U DISK 05/10/2010 21:56:33 2 1 NO HOTBKUP201005102149_DB
64362 B F U DISK 05/10/2010 21:56:37 1 1 NO HOTBKUP201005102149_DB
64390 B A U DISK 05/10/2010 21:58:02 1 1 NO HOTBKUP201005102149_ARCHLOGS
64508 B F U DISK 05/11/2010 03:07:01 2 1 NO HOTBKUP201005110300_DB
64509 B F U DISK 05/11/2010 03:07:10 1 1 NO HOTBKUP201005110300_DB
64544 B A U DISK 05/11/2010 03:07:47 1 1 NO HOTBKUP201005110300_ARCHLOGS
64761 B F U DISK 05/12/2010 03:06:23 2 1 NO HOTBKUP201005120300_DB
64762 B F U DISK 05/12/2010 03:06:30 1 1 NO HOTBKUP201005120300_DB
64792 B A U DISK 05/12/2010 03:08:13 1 1 NO HOTBKUP201005120300_ARCHLOGS
RMAN> crosscheck backup;
using channel ORA_DISK_1
RMAN> report obsolete recovery window of 1 days;
Report of obsolete backups and copies
Type Key Completion Time Filename/Handle
Backup Set 64362 05/10/2010 21:56:37
Backup Piece 64366 05/10/2010 21:56:37 /oracle_admin/rman_backups/201005102149/RMAN_HOTBKUP_IPCSD_201005102149_BS_1355_PC_1_CP_1_DB
Backup Set 64509 05/11/2010 03:07:10
Backup Piece 64520 05/11/2010 03:07:10 /oracle_admin/rman_backups/201005110300/RMAN_HOTBKUP_IPCSD_201005110300_BS_1358_PC_1_CP_1_DB
RMAN> -
Can't delete obsolete and expired backups.
Every Sundays I create 0 level backup.
Every Thuesdays I create 1 level comulative backup.
Every other days I create 1 level incremental backup.
Sometimes I need a free space for new backups and I try clean old backups.
As I can understand, rman remove backups from 'list backup', but doens't delete physically from disk storage.
SQL> select banner from v$version;
BANNER
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
PL/SQL Release 11.2.0.2.0 - Production
CORE 11.2.0.2.0 Production
TNS for Solaris: Version 11.2.0.2.0 - Production
NLSRTL Version 11.2.0.2.0 - Production
0 level backup
CONNECT TARGET / ;
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/u06/backup/df_%d_%s_%U';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/u06/backup/cf_%F';
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 3 DAYS;
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u06/backup/snapcf.f';
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE MAXSETSIZE TO 20G;
BACKUP CURRENT CONTROLFILE;
BACKUP INCREMENTAL LEVEL 0 DATABASE FILESPERSET 100 ;
BACKUP ARCHIVELOG ALL DELETE ALL INPUT;
RESTORE VALIDATE DATABASE;
RESTORE VALIDATE CONTROLFILE TO '$ORACLE_BASE/admin/rman_scripts/cf_tmp.ctl';
RESTORE VALIDATE SPFILE TO '$ORACLE_BASE/admin/rman_scripts/spf_tmp.ora';
RESTORE VALIDATE ARCHIVELOG FROM TIME 'SYSDATE-4';
REPORT NEED BACKUP;
DELETE OBSOLETE;
LIST BACKUP;
LIST BACKUP SUMMARY;
1 level comulative backup
CONNECT TARGET / ;
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/u06/backup/df_%d_%s_%U';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/u06/backup/cf_%F';
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 3 DAYS;
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u06/backup/snapcf.f';
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE MAXSETSIZE TO 20G;
BACKUP CURRENT CONTROLFILE;
BACKUP INCREMENTAL LEVEL 1 CUMULATIVE DATABASE FILESPERSET 100;
BACKUP ARCHIVELOG ALL DELETE ALL INPUT;
RESTORE VALIDATE DATABASE;
RESTORE VALIDATE CONTROLFILE TO '$ORACLE_BASE/admin/rman_scripts/cf_tmp.ctl';
RESTORE VALIDATE SPFILE TO '$ORACLE_BASE/admin/rman_scripts/spf_tmp.ora';
RESTORE VALIDATE ARCHIVELOG FROM TIME 'SYSDATE-4';
REPORT NEED BACKUP;
DELETE OBSOLETE;
LIST BACKUP;
LIST BACKUP SUMMARY;
1 level incremental backup
CONNECT TARGET / ;
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/u06/backup/df_%d_%s_%U';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/u06/backup/cf_%F';
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 3 DAYS;
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u06/backup/snapcf.f';
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE MAXSETSIZE TO 20G;
BACKUP CURRENT CONTROLFILE;
BACKUP INCREMENTAL LEVEL 1 DATABASE FILESPERSET 100;
BACKUP ARCHIVELOG ALL DELETE ALL INPUT;
RESTORE VALIDATE DATABASE;
RESTORE VALIDATE CONTROLFILE TO '$ORACLE_BASE/admin/rman_scripts/cf_tmp.ctl';
RESTORE VALIDATE SPFILE TO '$ORACLE_BASE/admin/rman_scripts/spf_tmp.ora';
RESTORE VALIDATE ARCHIVELOG FROM TIME 'SYSDATE-4';
REPORT NEED BACKUP;
DELETE OBSOLETE;
LIST BACKUP;
LIST BACKUP SUMMARY;
Try delete old backups:
CONNECT TARGET / ;
RMAN> CROSSCHECK BACKUP;
Crosschecked 173 objects
RMAN> DELETE EXPIRED BACKUP;
using channel ORA_DISK_1
specification does not match any backup in the repository
RMAN> DELETE OBSOLETE;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 3 days
using channel ORA_DISK_1
no obsolete backups found
RMAN>
Edited by: 848540 on 31.10.2011 23:15I try to ask one more time.
I make all backups in the folder \u06\backup.
I make full backups every week.
After command "crosscheck backup" all backups older 2 weeks must be mark as "OBSOLETE". This operation works correctly, becouse in "list backup" i look all backups for last two weeks and no older (for today they all made earlyer then 06/11/2011)!
After crosscheck operation i try to delete old backups from HDD.
RMAN> delete expired backup;
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=2 device type=DISK
specification does not match any backup in the repository
RMAN> delete obsolete;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 3 days
using channel ORA_DISK_1
no obsolete backups found
But after this operation I look in my backup folder files since 02/10/2011. How to sync backups (delete obsolete backups from HDD) in rman list (command 'list backup') and in operation system list (command 'ls' in sun10)?
Edited by: 848540 on 14.11.2011 0:32 -
RUN "delete noprompt obsolete" before "backup database"
Hello,
11g on windows 2003, 3 day recovery window
For almost a year now, I having been running the below script daily to backup my database. Now I am begining to run out of disk space, and can not run the backup commands unless I run "delete noprompt obsolete" first.
backup database tag=database_full_backup;
backup archivelog all delete input tag=achivelog_backup;
crosscheck backup;
delete expired backup;
delete noprompt obsolete;
Is it a bad idea to rearange the order of the commands like below?
crosscheck backup;
delete expired backup;
delete noprompt obsolete;
backup database tag=database_full_backup;
backup archivelog all delete input tag=achivelog_backup;
thanks for any helpHi,
No problem. You configured a recovery window of 3 days, it means you want to be able to restore/recover until sysdate - X (X up to 3) at any time. RMAN will always respect that, you can "delete obsolete" whenever you want.
Best regards
Phil -
Crosscheck backup and delete obsolete;
Hi,
on 10g R2 on a Win 2003. Connected to catalog and Target database I issue :
RMAN>crosscheck backup
RMAN>delete obsolete;
FILE 1
FILE 2
Do you want to delet the above file ? Y/N :YES
Then again :
RMAN>crosscheck backup
RMAN>delete obsolete;
FILE 1
FILE 2
Do you want to delet the above file ? Y/N
I can not understand. If the first time I answered YES and the obsolete files where deleted why they appear again and again ?
Can any one be kind to explain me ?
Thank you.'crosscheck' has nothing to do with obsolete backups, this command checks for backups,which are still recorded in the controlfile/recovery catalog,but don't exist physically on disk/tape. The correct command after a 'crosscheck' is 'delete expired', 'obsolete' are backups no longer needed due to the defined retention policy.
I guess your backups are both , obsolete and expired, but 'delete obsolete' does not work, because these backups were removed outside RMAN. It could also be a permission problem, RMAN is not allowed to remove the backups on OS level. That happens on Windows, when shared drives are used.
Werner -
Hi, hoping someone will have the answer for me.
Oracle 10g R2 on Windows 2003 R2 Sever.
The start of my RMAN script runs, i do crosschecks and delete obsolete backups from type disk. My redundancy is set to 1. I then run compressed backups of the datafiles and archivelogs with 2 channels. This leaves me with two days of full backups on disk (i have months worth on netbackup) the only problem is that one of the archivelog channel backups from the previous day is missing when i know it was there before the delete obsolete was run.
here is the script:
run{
CROSSCHECK BACKUP;
CROSSCHECK archivelog all;
CROSSCHECK COPY;
CROSSCHECK backup of database;
CROSSCHECK backup of controlfile;
delete noprompt obsolete device type disk;
run {
allocate channel ch1 type disk format 'Z:\backup\rman\orcl\%d_%T_%U';
allocate channel ch2 type disk format 'Z:\backup\rman\orcl\%d_%T_%U';
backup as COMPRESSED BACKUPSET
format='Z:\backup\rman\orcl\full_%d_%T_%U'
tag='full_DBbackup_ris'
database;
backup as COMPRESSED BACKUPSET
format='Z:\backup\rman\orcl\arch_%d_%T_%U'
tag='full_ARCHbackup_ris'
archivelog all not backed up delete all input;
sql "alter database backup controlfile to trace as ''Z:\backup\rman\orcl\controlfile_backup_trace.txt''";
release channel ch1;
release channel ch2;
This is my (simplified) list of backups on disk:
Full_day1_chan1
Full_day1_chan2
Arc_day1_chan1
Arc_day1_chan2
Full_day2_chan1
Full_day2_chan2
Arc_day2_chan1
It looks like channel2, days2, archivelog backup is missing. Is this correct? If not does anyone have an idea how to fix this?
thanks in advance.
Steven.Hi Steven,
The data backed up by rman is written to backup pieces.
Are you missing pieces containing archive logs?
Could it be there was only 1 arc file available so the second channel could not create any backup piece?
Did you could check the output of the backup in v$rman_output?
Regards,
Tycho
Maybe you are looking for
-
What are the master loads in Fi/Co
Hi to every one I was assigned by one work, which is i have to work the idenatification of master datas in Fi/Co. After that our technical people will migrate the data using BDC. So i identified few master datas in Fi/Co. those are 1. GL master 2. Ho
-
Can't connect to Mac Pro from Macbook Pro on finder
Hi there was wondering if someone can help me out with this? I used to be able to connect through the side panel on the finder with my macbook to my mac pro and vice versa. I had not used this function in a few months and tried the other day and it
-
Debugging of any Application on WAS
Hello Everybody, Can two developers can debug the same application at the same time on the same server? If not, then can two developers can debug the different but dependant applications at the same time on the same server? What are the possible opti
-
How do i get my radio to work? (Zen Mic
What shall i do to get my radio to play insted of just crashing noises? Please help me guys I really wants to listen to the radio
-
BPC Netweaver dimension formula SUM and AGGREGATE
Hello Does anybody knows the arguments we can use with SUM and AGGREGATE in a dimension formula in BPC NW. I would like to aggregate data on a hirarchy but not from leaf level only the child at a specific level (do an average at a certain level and t