Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Control File Backup

Re: Control File Backup

From: VA Access <vaaccess_at_my-deja.com>
Date: Tue, 06 Feb 2001 19:12:11 GMT
Message-ID: <95pia1$kbt$1@nnrp1.deja.com>

I guess I should have stated that the system is in backup mode at the time of the command execution that I listed below. All of the tablespaces are put into backup mode by executing the following command for each tablespace:

alter tablespace SYSTEM begin backup;

Then, the ocopy73 commands are executed to copy the datafiles and the control file is copied as well. What is happening is that the control file wasn't copying when the AT commands are executed, but would copy when I ran the commands by double-clicking on the .cmd file that started the process.
I changed the commands so it will copy the control files with a dos copy command instead of the Oracle ocopy command. We'll see if that works tonight.

However, based on what you're saying the consultant that set all this up didn't do it correctly. By using the "alter database backup controlfile" command that you mentioned, how would I get the control files and all the datafiles to be in sync? Could the "alter database backup controlfile" command be run during the backup of the datafiles?

What is the best way to do a backup, then? Right now I could take the database offline and copy the files and bring it back up nightly. That wouldn't be a big problem...

Thanks for the help.
Mike

In article <3a7b410e$1_at_news.iprimus.com.au>,   "Howard J. Rogers" <howardjr_at_www.com> wrote:
> You don't say what is going wrong, and I'm assuming you physically
 aren't
> getting a copy of your Control File in the requisite directory, but
 let me
> tell you straight up that even if it was working, your backup would be
> worthless.
>
> You can NOT take hot backups of ANYTHING in Oracle, unless you have
> something that can make the resulting inconsistent mess consistent
 once
> more.
>
> Now with datafiles, we have redo. Applying redo makes inconsistent
> datafiles consistent. The restored files can thus be made useable,
 provided
> all required redo is applied.
>
> What do we have that we can apply to Control Files? Er... nothing.
>
> You therefore cannot just copy Control Files whilst the database is
 hot.
> For this reason, Oracle cunningly invented the piece of SQL
 syntax: 'alter
> database backup controlfile to 'd:\blah\blah\blah.bkp' -since this
 command
> causes Oracle itself to generate the requisite consistent image.
 Unless you
> use that command (or, preferably, it's trace file cousin), your
 control file
> backups will be unuseable when it comes to the crunch.
>
> Regards
> HJR
>
> "VA Access" <vaaccess_at_my-deja.com> wrote in message
> news:95f1j5$g4s$1_at_nnrp1.deja.com...
> > Each night I run a process that puts the DB into hot backup mode and
> > then copies the db files to a directory which is backed up a little
 bit
> > later. Anyway, I noticed that the Control Files are not getting
 copied
> > correctly, but all the datafile are doing just fine. So, my
 question
> > is, why?
> >
> > Here's what happens:
> > SQL runs that puts all the tablespaces into backup mode.
> >
> > Then, the copying occurs. Here's a snipit:
> > PLUS33W.EXE sys/PASSWORD_at_INSTANCE
> > d:\orant\bin\ocopy73 d:\orant\database\CTL1CODA.ORA
 d:\dba_admin\backup
> > d:\orant\bin\ocopy73 d:\orant\database\LOG1CODA.ORA
 d:\dba_admin\backup
> >
> >
> > Sent via Deja.com
> > http://www.deja.com/
>
>

Sent via Deja.com
http://www.deja.com/ Received on Tue Feb 06 2001 - 13:12:11 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US