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: different ways of archiving current redo log

Re: different ways of archiving current redo log

From: Prem K Mehrotra <premmehrotra_at_hotmail.com>
Date: 23 Mar 2004 19:00:05 -0800
Message-ID: <43441e77.0403231900.5fa71b0a@posting.google.com>


"Howard J. Rogers" <hjr_at_dizwell.com> wrote in message news:<40608af5$0$8356$afc38c87_at_news.optusnet.com.au>...
> "Prem K Mehrotra" <premmehrotra_at_hotmail.com> wrote in message
> news:43441e77.0403231048.373be43d_at_posting.google.com...
> > I have seen different ways of archiving logs and want to clarify their
> > usage:
> >
> > 1. alter system switch logfile
> >
> > Does this command really archives current redo log before switch, or
> > it simply switches and archiving is done later in background
> > (asynchronus manner)
>
> Switch logfile instructs LGWR to start writing to another online log. ARCn
> also gets a message to start archiving the log just switched away from.
>
> > 2. alter system archive log current:
> > I will think this command will actually archive the current log and
> > then only swtch to next log, i.e, archiving and next log are
> > synchronus operations.
>
> Here's a little test you might try:
>
> SQL> archive log list
> Database log mode Archive Mode
> Automatic archival Disabled
> Archive destination C:\
> Oldest online log sequence 151
> Next log sequence to archive 152
> Current log sequence 153
>
> SQL> alter system archive log current;
>
> System altered.
>
> SQL> archive log list
> Database log mode Archive Mode
> Automatic archival Disabled
> Archive destination C:\
> Oldest online log sequence 152
> Next log sequence to archive 154
> Current log sequence 154
>
> You might notice that the log sequence numbers have changed, indicating that
> LGWR is certainly aware of the effects of the command. But you'll notice
> that my ARCn process is actually disabled and therefore cannot possibly have
> archived the current log. So how synchronous do you think the operations
> are?
>
> There is in fact precious little difference between 'archive log current'
> and 'switch logfile'.
>
> > 3. alter system archive log all:
> > This command will archive all filled redo logs but will not complete
> > current log because it will not be full.
>
> About right.
>
> Regards
> HJR
>
>
>
>
> >
> >
> > Thanks,
> >
> > Prem

HJR:
Thanks, Regrading question 2, even though your automatic archiving is disabled, manual archiving can still be done. When you say precious liitle difference, do you mean there is no difference between 2 and 1. You response on 1 is similar to my thinking but Syad's response seems to say that   alter system switch logfile
may archive the log as well as switch. This where I get confused, there is no gurantee that archiving has been completed with alter system switch log file.

Prem Received on Tue Mar 23 2004 - 21:00:05 CST

Original text of this message

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