Home » Server Options » Data Guard » ora-00314 after "alter system switch logfile"
ora-00314 after "alter system switch logfile" [message #282942] Sun, 25 November 2007 07:16 Go to next message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
Hi All,

As a learning experience I thaugth "let's set up dataguard on my windows system (XP)"

On the system is oracle installed (10.2.0.1)

I followed the guidelines from: http://download.oracle.com/docs/cd/B14117_01/server.101/b10823/create_ps.htm#63563



The pfile of the primary datbase (prim) looks like :
Quote:


prim.__db_cache_size=96468992
prim.__java_pool_size=4194304
prim.__large_pool_size=4194304
prim.__shared_pool_size=58720256
prim.__streams_pool_size=0
*.audit_file_dest='C:\oracle\product\admin\prim\adump'
*.background_dump_dest='C:\oracle\product\admin\prim\bdump'
*.compatible='10.2.0.1.0'
*.control_files='C:\oradata\db\prim\control01.ctl','C:\oradata\db\prim\control02.ctl','C:\oradata\db\prim\control03.ctl'
*.core_dump_dest='C:\oracle\product\admin\prim\cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.job_queue_processes=10
*.log_archive_format='ARC%S_%R.%T'
*.open_cursors=300
*.pga_aggregate_target=55574528
*.processes=150
*.sga_target=168820736
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='C:\oracle\product\admin\prim\udump'
DB_NAME=prim
DB_UNIQUE_NAME=prim
LOG_ARCHIVE_CONFIG='DG_CONFIG=(prim,phys)'
LOG_ARCHIVE_DEST_1='LOCATION=c:\oradata\arch\prim\ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=prim'
LOG_ARCHIVE_DEST_2='SERVICE=phys LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=phys'
LOG_ARCHIVE_DEST_STATE_1=ENABLE
LOG_ARCHIVE_DEST_STATE_2=ENABLE
REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE
LOG_ARCHIVE_MAX_PROCESSES=5



The pfile of the physical standby database (phys) looks like :
Quote:


prim.__db_cache_size=96468992
prim.__java_pool_size=4194304
prim.__large_pool_size=4194304
prim.__shared_pool_size=58720256
prim.__streams_pool_size=0
*.audit_file_dest='C:\oracle\product\admin\phys\adump'
*.background_dump_dest='C:\oracle\product\admin\phys\bdump'
*.compatible='10.2.0.1.0'
*.control_files='C:\oradata\db\phys\control01.ctl','C:\oradata\db\phys\control02.ctl','C:\oradata\db\phys\control03.ctl'
*.core_dump_dest='C:\oracle\product\admin\phys\cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.DB_NAME='prim'
*.DB_UNIQUE_NAME='phys'
*.job_queue_processes=10
*.LOG_ARCHIVE_CONFIG='DG_CONFIG=(prim,phys)'
*.LOG_ARCHIVE_DEST_1='LOCATION=c:\oradata\arch\phys\ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=phys'
*.LOG_ARCHIVE_DEST_2='SERVICE=prim LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=prim'
*.LOG_ARCHIVE_DEST_STATE_1='ENABLE'
*.LOG_ARCHIVE_DEST_STATE_2='ENABLE'
*.log_archive_format='ARC%S_%R.%T'
*.LOG_ARCHIVE_MAX_PROCESSES=5
*.open_cursors=300
*.pga_aggregate_target=55574528
*.processes=150
*.REMOTE_LOGIN_PASSWORDFILE='EXCLUSIVE'
*.sga_target=168820736
*.undo_management='AUTO'
*.undo_tablespace='UNDOTBS1'
*.user_dump_dest='C:\oracle\product\admin\prim\udump'
DB_FILE_NAME_CONVERT='prim','phys'
LOG_FILE_NAME_CONVERT='c:\oradata\arch\prim\','c:\oradata\arch\phys\'
FAL_SERVER=prim
FAL_CLIENT=phys
standby_file_management=auto



As one of the last steps, to check whether the standby database receives and applies the logfiles from the primary, I do (on the primary database):
Quote:



SQL> select status from v$instance;

STATUS
------------
OPEN

SQL> ALTER SYSTEM SWITCH LOGFILE;
ALTER SYSTEM SWITCH LOGFILE
*
ERROR at line 1:
ORA-00314: log of thread , expected sequence# doesn't match




I most probably forgot something or made a mistake in the configuration, but.... I don;t see it.

Can anyone shine a light on what maybe a cause of this.

Best regards,

Martijn
Re: ora-00314 after "alter system switch logfile" [message #282943 is a reply to message #282942] Sun, 25 November 2007 07:23 Go to previous messageGo to next message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
Some additional information:

I did not create standby logfiles on the primary database, although oracle suggests it. This because the documentation tells me that these logs are only used in case of an role-transition. This I am not planning to do. First I want to see whether I can make it work 1-way (which proves to be not so easy to me Embarassed).

Best regards,

Martijn
Re: ora-00314 after "alter system switch logfile" [message #282945 is a reply to message #282943] Sun, 25 November 2007 07:32 Go to previous messageGo to next message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

DB_FILE_NAME_CONVERT='prim','phys'
You have to specify complete path instead of service name.

ORA-00314: log string of thread string, expected sequence# string doesn't match string
Cause: The online log is corrupted or is an old version.
Action: Find and install correct version of log or reset logs


Re: ora-00314 after "alter system switch logfile" [message #282946 is a reply to message #282945] Sun, 25 November 2007 07:48 Go to previous messageGo to next message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
Oh yeah... thanx I see what you mean.
I changedit in both pfiles and created new spfiles from them.

The standby datbase does start:
Quote:


SQL> startup
ORACLE instance started.

Total System Global Area 171966464 bytes
Fixed Size 1247900 bytes
Variable Size 62915940 bytes
Database Buffers 100663296 bytes
Redo Buffers 7139328 bytes
Database mounted.
Database opened.
SQL>



The primary did not:
Quote:


SQL> startup
ORACLE instance started.

Total System Global Area 171966464 bytes
Fixed Size 1247900 bytes
Variable Size 67110244 bytes
Database Buffers 96468992 bytes
Redo Buffers 7139328 bytes
Database mounted.
ORA-00314: log 3 of thread 1, expected sequence# 9 doesn't match 0
ORA-00312: online log 3 thread 1: 'C:\ORADATA\DB\PRIM\REDO03.LOG'



The ora message I allready looked up:-)
What I do not understand is what causes it and how to solve it.

Best Regards Martijn
Re: ora-00314 after "alter system switch logfile" [message #282955 is a reply to message #282946] Sun, 25 November 2007 09:32 Go to previous messageGo to next message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

http://mennan.kagitkalem.com/SolutionOfORA00314LogOfThreadExpectedSequenceDoesntMatch.aspx
http://searchoracle.techtarget.com/ateQuestionNResponse/0,289625,sid41_cid565670_tax294551,00.html


Re: ora-00314 after "alter system switch logfile" [message #283279 is a reply to message #282955] Mon, 26 November 2007 10:30 Go to previous messageGo to next message
DreamzZ
Messages: 1666
Registered: May 2007
Location: Dreamzland
Senior Member
Try this but make sure your are on TEST server.
1.- Startup Mount
2.- Recover Until Cancel
3.- Alter Database Open Reselogs
Re: ora-00314 after "alter system switch logfile" [message #283324 is a reply to message #283279] Mon, 26 November 2007 13:26 Go to previous messageGo to next message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
hehehe I'm working on my laptop (it's a learning experience). So if I crash the DB there is no problem whatsoever.

I will try your suggestion.

tnx. Martijn
Re: ora-00314 after "alter system switch logfile" [message #283325 is a reply to message #282955] Mon, 26 November 2007 13:30 Go to previous messageGo to next message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
thanks Mohammed,

I think your suggestions lead in the same direction as the suggestion Dreamzz presented later.

I will certainly try.

<retorical>
I wonder what I'm doing wrong because I think I'm doing what the oracle documentation is telling me.
</retorical>

Best regards,

Martijn
Re: ora-00314 after "alter system switch logfile" [message #283356 is a reply to message #283325] Mon, 26 November 2007 22:38 Go to previous messageGo to next message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

I think I'm doing what the oracle documentation is telling me.
Smile but you done something wrong...which you did not think.
Re: ora-00314 after "alter system switch logfile" [message #283463 is a reply to message #283356] Tue, 27 November 2007 04:34 Go to previous message
martijn
Messages: 283
Registered: December 2006
Location: Netherlands
Senior Member
Mohammad Taj wrote on Tue, 27 November 2007 05:38

I think I'm doing what the oracle documentation is telling me.
Smile but you done something wrong...which you did not think.


exactly...Very Happy
Previous Topic: Real-time Redo Apply
Next Topic: adding a tablespace in primary database
Goto Forum:
  


Current Time: Sun Dec 11 04:16:05 CST 2016

Total time taken to generate the page: 0.07702 seconds