Home » RDBMS Server » Server Administration » Starting Archive loggin in a Cloned database
Starting Archive loggin in a Cloned database [message #50871] Thu, 11 April 2002 14:19 Go to next message
Hector M. Villarreal
Messages: 8
Registered: January 2002
Junior Member
I am cloning a database as follows:
1.) generate a backup copy of the controlfile to trace.
2.) edit the trace file to create new database name with datafiles in new paths.
3.) then perform some recovery with backup log files.

4.) after that I attempt to turn on archivelog mode
alter database archivelog;
It always fails.

5.) I have reviewed init.ora file and have following setup:
log_archive_start = true
log_archive_dest_1 = "location=/oradumps/kanarsp2/arch"
log_archive_format = arch_%t_%s.arc

My new database name is kanarsp2.
original database was called kanarsp1.

Is there a way to make archivelog start in a cloned database?
Re: Starting Archive loggin in a Cloned database [message #50891 is a reply to message #50871] Fri, 12 April 2002 06:52 Go to previous messageGo to next message
Grant
Messages: 578
Registered: January 2002
Senior Member
You need to be specific on the error message you are getting for us to help. What procedure did you follow to turn on archiving? Assuming you have the required parameters set as stated you need to:

svrmgrl> shutdown immediate;
svrmgrl> startup mount;
svrmgrl> alter database archivelog;
svrmgrl> alter database open;
svrmgrl> archive log list;

If you get errors in the above commands please post them.
Re: Starting Archive loggin in a Cloned database [message #50895 is a reply to message #50891] Fri, 12 April 2002 11:41 Go to previous messageGo to next message
Hector M. Villarreal
Messages: 8
Registered: January 2002
Junior Member
I produced the following output. But the logs are not generated. I go to the log file and it is not generating any log files.

ORACLE instance started.
Total System Global Area 31928228 bytes
Fixed Size 94116 bytes
Variable Size 14966784 bytes
Database Buffers 16777216 bytes
Redo Buffers 90112 bytes
Database mounted.
SVRMGR> alter database archivelog;
alter database archivelog
*
ORA-00265: instance recovery required, cannot set ARCHIVELOG mode
SVRMGR> recover database;
ORA-00283: recovery session canceled due to errors
ORA-00264: no recovery required
SVRMGR> alter database open;
Statement processed.
SVRMGR> archive log list;
Database log mode No Archive Mode
Automatic archival Enabled
Archive destination /oradumps/kanarsp2/arch
Oldest online log sequence 4
Current log sequence 6

hector@kanadb01(arch): svrmgrl

Oracle Server Manager Release 3.1.6.0.0 - Production

Copyright (c) 1997, 1999, Oracle Corporation. All Rights Reserved.

Oracle8i Enterprise Edition Release 8.1.6.0.0 - 64bit Production
With the Partitioning option
JServer Release 8.1.6.0.0 - Production

SVRMGR> connect internal;
Connected.
SVRMGR> select * from v$database;
DBID NAME CREATED RESETLOGS_ RESETLOGS PRIOR_RESE PRIOR_RES LOG_MODE CHECKPOINT ARCHIVE_CH CONTROL CONTROLFI CONTROLFIL CONTROLFIL CONTROLFI OPEN_RESETL VERSION_T OPEN_MODE
---------- --------- --------- ---------- --------- ---------- --------- ------------ ---------- ---------- ------- --------- ---------- ---------- --------- ----------- --------- ----------
4010741211 KANARSP2 11-APR-02 17880329 11-APR-02 1 07-JUN-01 NOARCHIVELOG 17981065 17961020 CURRENT 11-APR-02 129032 17981105 12-APR-02 NOT ALLOWED 11-APR-02 READ WRITE
1 row selected.
SVRMGR>
Re: Starting Archive loggin in a Cloned database [message #50897 is a reply to message #50891] Fri, 12 April 2002 12:01 Go to previous messageGo to next message
Grant
Messages: 578
Registered: January 2002
Senior Member
Did you specify "RESETLOGS" in the create database statement when you cloned? Have you tried:

svrmgrl> startup mount;
svrmgrl> alter database open resetlogs; REM Required

The last command needs to be added to your trace file when you create the clone. Here is a good link short and to the point: http://www.dbascripts.com/all_scripts/index.asp?group=Cloning
Re: Starting Archive loggin in a Cloned database [message #50900 is a reply to message #50891] Fri, 12 April 2002 13:30 Go to previous messageGo to next message
Hector M. Villarreal
Messages: 8
Registered: January 2002
Junior Member
I did perform these commands when I originally cloned the database:

svrmgrl> startup mount;
svrmgrl> Revcover database using backup controlfile until cancel;
REM Goes thru the log files needed to recover it.

svrmgrl> alter database open resetlogs;

The archive log still does not run.
Re: Starting Archive loggin in a Cloned database [message #50926 is a reply to message #50891] Mon, 15 April 2002 08:32 Go to previous messageGo to next message
Grant
Messages: 578
Registered: January 2002
Senior Member
You should not have to recover if you did it correctly. I would suggest you do it again. When you copy the files from the original make sure you have done a clean shutdown. Here is a good link that you may want to look at on how to properly clone a DB.

http://www.dbascripts.com/all_scripts/index.asp?group=Cloning
Re: Starting Archive loggin in a Cloned database [message #50933 is a reply to message #50891] Mon, 15 April 2002 13:34 Go to previous message
Hector Villarreal
Messages: 1
Registered: April 2002
Junior Member
Thanks for the dba scripts site.

I can clone and archive log as described in the writeup.
However, I am attempting to clone from a backup that ran the day before.
Then apply logs to catch it up to current. This is the scenario
where the database is lost or corrupted to the point where you cannot
shutdown and copy over the datafiles.

The idea is to copy a hot backup from the night before and appy the logs.
That works fine until you wan to start archiving. It never can do it. It may be that
the cloned version from a backup with recovery applied cannot have archivelog re-started.

thanks
Hector
Previous Topic: Re: Setting Storage Parameters - Initial Extent
Next Topic: Re: ORA-12500: TNS:listener failed to start a dedicated server process
Goto Forum:
  


Current Time: Mon Sep 09 18:55:29 CDT 2024