Re: controlfile autobackup (was: Re: disaster recovery)

From: <sybrandb_at_hccnet.nl>
Date: Tue, 20 May 2008 21:14:03 +0200
Message-ID: <5f86341l32je7030o1flmknamh54kk46jf@4ax.com>


On Tue, 20 May 2008 09:25:57 -0700 (PDT), joel garry <joel-garry_at_home.com> wrote:

>On May 17, 9:55 am, sybra..._at_hccnet.nl wrote:
>> On Fri, 16 May 2008 13:02:36 -0700 (PDT), Ben <benal..._at_yahoo.com>
>> wrote:
>
>>
>> >now that we've lost the catalog, spfile, controlfiles, and everything
>> >else. Is there a way to get the controlfile and spfile out of that
>> >backup?
>>
>> If you didn't have controlfile autobackup on, which you didn't
>> specify, shortly : NO.
>
>I have a recently installed hp-ux 10.2.0.3 with autobackup on. It's
>just idling along while I do app development on another machine. This
>thread made me take a closer look at the autobackup. I check the
>alert log, I see it is writing controlfile backups to specific files
>in directories with each days date on them, makes sense since I'm
>taking a full backup each day (I haven't set up a repository yet). It
>seems to be keeping a weeks worth of these directories, but I only
>just noticed it only is keeping the latest controlfile backup. Seems
>not paranoid enough to me. I have CONFIGURE RETENTION POLICY TO
>REDUNDANCY 2;
>
>The script as generated by the customization wizard is this:
>
>$rman_script="backup device type disk tag '%TAG' database;
>backup device type disk tag '%TAG' archivelog all not backed up;
>allocate channel for maintenance type disk;
>delete noprompt obsolete device type disk;
>release channel;
>";
>
>Am I wrong to expect the delete obsolete to keep two of the
>controlfile/spfile backups? Or is it just also in the regular backup
>files?
>
>Looking at the rman log, I see what is happening: It is backing up
>the controlfile/spfile once for the archivelog backup, then once again
>for the regular backup, then deleting all the others. So it is
>keeping two, from the same time - the log appears to have them before
>and after the backup, but the unix time is the same (I assume because
>rman must have closed the files at nearly the same time).
>
>This seems strange, how should I be doing this? Shouldn't I want to
>have some spread of controlfile backup times, to avoid just
>propagating a messed up one when restoring?
>
>jg

Joel,

I can only investigate this for 9i. I don't think 10g has changed in this regard, so that should be OK. I ran into something strange today which I need to investigate anyway: my autobackups also seem to disappear, though my retention is 9 days.

One question though:
Do you happen to use backup optimization. I noticed using backup optimization in 9i you can only backup the archivelogs once, whatever you tell it to do. It begins to brag you already have a backup of the archivelogs. Sounds equally scary.
The behavior with autobackup controlfile may be the same issue. The reasoning might be you have records of multiple backups in the controlfile anyway, so you should be OK.

Hth

-- 
Sybrand Bakker
Senior Oracle DBA
Received on Tue May 20 2008 - 14:14:03 CDT

Original text of this message