After part I:the problem, Part II: two reports here is part III.
We have backed up archivelog during a full and deleted them before the full completed.
RMAN> list backup of archivelog all;
List of Backup Sets
===================
BS Size Type Elapsed Completion
-- ------ ---- -------- ----------
15 4.00K DISK 00:00:00 13:31:08
BP Key: 15 Status: AVAILABLE
Piece Name: /FULL/0fq7gc0s_1_1
List of Archived Logs in backup set 15
Seq LowSCN LowTime NextSCN NextTime
--- ------- -------- ------- --------
15 355533 13:29:55 355777 13:31:08
BS Size Type Elapsed Completion
-- ------ ---- -------- ----------
25 4.00K DISK 00:00:00 13:31:26
BP Key: 25 Status: AVAILABLE
Piece Name: /ARCH/0pq7gc1e_1_1
List of Archived Logs in backup set 25
Seq LowSCN LowTime NextSCN NextTime
--- ------- -------- ------- --------
15 355533 13:29:55 355777 13:31:08
BS Size Type Elapsed Completion
-- ------ ---- -------- ----------
26 3.00K DISK 00:00:00 13:31:26
BP Key: 26 Status: AVAILABLE
Piece Name: /ARCH/0qq7gc1e_1_1
List of Archived Logs in backup set 26
Seq LowSCN LowTime NextSCN NextTime
--- ------- -------- ------- --------
16 355777 13:31:08 355827 13:31:22
BS Size Type Elapsed Completion
-- ------ ---- -------- ----------
28 2.50K DISK 00:00:00 13:31:28
BP Key: 28 Status: AVAILABLE
Piece Name: /FULL/0sq7gc1g_1_1
List of Archived Logs in backup set 28
Seq LowSCN LowTime NextSCN NextTime
--- ------- -------- ------- --------
17 355827 13:31:22 355863 13:31:28
Sequence 16 is missing in /FULL/ and is available in /ARCH/
Ok, let’s copy the missing pieces from ARCH to FULL
$ cd /
$ cp -p ARCH/* FULL/
Now let’s try. I save my directory on an offline location (tape/usb/cdrom) and dropped my database including backups.
cd /
tar cvf /tmp/FULL.tar FULL
Let’s drop (it’s just a test)
RMAN> startup force mount dba
RMAN> drop database including backups;
database dropped
Ok let’s get this USB stick back from the moon to my datacenter and see if I can restore …
cd /
tar xvf /tmp/FULL.tar
Let’s do this !
RMAN> startup force nomount
RMAN> restore controlfile from '/FULL/c-2414975447-20150521-01';
RMAN> alter database mount;
Now I want RMAN to look for other files in FULL and also marked expired stuff. The start with
does the magic.
RMAN> catalog start with '/FULL/' noprompt;
RMAN> crosscheck backup;
RMAN> crosscheck copy;
RMAN> crosscheck archivelog all;
RMAN> restore database;
RMAN> recover database;
RMAN> alter database open resetlogs;
As @dbastorage said on twitter:
“if it was easy, we would not need DBAs! ”
@laurentsch and have a job to backup the before backup redo, that includes the delete… if it was easy, we would not need DBAs! 🙂 2/2
— Peter Herdman-Grant (@AgnosticDBA) May 20, 2015