Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to configure Dataguard Broker in Oracle physical DG automatic handover

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly introduces the Oracle physical DG automatic switching in how to configure Dataguard Broker, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.

1.1 introduction

Configuration of ① Data Guard Broker

Client TAF configuration for ③ Oracle DataGuard

Some sql managed and maintained by ⑤ physical dg

List of Archived Logs in backup set 11

-

1 33 1625242 2015-05-29 11:15:48 1625293 2015-05-29 11:15:58

2 43 1625245 2015-05-29 11:15:49 1625253 2015-05-29 11:15:53

3.1 Experimental objectives

3.2 prerequisites

1. Set primary and standby startup parameter files to spfile

3. Set up listener

In a Data Guard Broker environment, you need to statically add a registration with a service_name of db_unique_name_DGMGRL.db_domain to listener.ora. This service_name will be used when DGMGRL restarts the database. When the database is restarted through DGMGRL, the DMON process shuts down the database first, and then DGMGRL uses this service_name to connect to the database through listener and issue a startup command.

Main library operation:

Connect to:

With the Partitioning, OLAP, Data Mining and Real Application Testing options

10:17:04 SQL > show parameter name

NAME TYPE VALUE

Db_file_name_convert string oradglg, oradg11g

Db_unique_name string oradg11g

Instance_name string oradg11g

Log_file_name_convert string oradglg, oradg11g

Service_names string oradg11g

-

/ dbhome_1/dbs/spfileoradg11g.o

10:17:14 SQL > show parameter DG_BROKER_CONFIG_FILE

NAME TYPE VALUE

Dg_broker_config_file1 string / u01/app/oracle/product/11.2.0

Dg_broker_config_file2 string / u01/app/oracle/product/11.2.0

10:20:43 SQL > set line 9999

10:20:44 SQL > col FS_FAILOVER_OBSERVER_HOST format A20

-

10:20:44 SQL > SELECT d.DBID

10:20:44 3 d.FORCE_LOGGING

10:20:44 5 d.FS_FAILOVER_STATUS

10:20:44 7 d.FS_FAILOVER_THRESHOLD

10:20:44 9 d.FS_FAILOVER_OBSERVER_HOST

10:20:45 SQL >

Oracle 7936 7895 0 10:21 pts/4 00:00:00 / bin/bash-c ps-ef | grep dmon

-

/ dbhome_1/dbs/dr1oradg11g.dat

/ dbhome_1/dbs/dr2oradg11g.dat

10:21:39 SQL > show parameter dg_broker_start

NAME TYPE VALUE

Dg_broker_start boolean FALSE

10:21:56 SQL >! Ps-ef | grep dmon

Oracle 7976 7895 0 10:22 pts/4 00:00:00 / bin/bash-c ps-ef | grep dmon

10:22:02 SQL > show parameter dg_broker_start

NAME TYPE VALUE

Dg_broker_start boolean TRUE

10:23:58 SQL > col name format A10

10:23:58 SQL > select dbid,name,current_scn,protection_mode,protection_level,database_role,force_logging,open_mode,switchover_status from v$database

DBID NAME CURRENT_SCN PROTECTION_MODE PROTECTION_LEVEL DATABASE_ROLE FOR OPEN_MODE SWITCHOVER_STATUS

1403587593 ORADG11G 2337043 MAXIMUM PERFORMANCE MAXIMUM PERFORMANCE PRIMARY YES READ WRITE TO STANDBY

Time spent: 00: 00: 00.01

10:23:58 2 d.DB_UNIQUE_NAME

10:23:58 4 d.FLASHBACK_ON

10:23:58 6 d.FS_FAILOVER_CURRENT_TARGET

10:23:58 8 d.FS_FAILOVER_OBSERVER_PRESENT

10:23:58 10 FROM v$database d

DBID DB_UNIQUE_NAME FOR FLASHBACK_ON FS_FAILOVER_STATUS FS_FAILOVER_CURRENT_TARGET FS_FAILOVER_THRESHOLD FS_FAIL FS_FAILOVER_OBSERVER

1403587593 oradg11g YES YES DISABLED 0

Time spent: 00: 00: 00.00

Mon Sep 28 10:21:56 2015

Mon Sep 28 10:21:56 2015

Starting Data Guard Broker (DMON)

INSV started with pid=38, OS id=7984

Prepare the library operation:

[oracle@rhel6_lhr ~] $sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Monday September 28 10:25:25 2015

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production

-

Db_name string oradg11g

Global_names boolean FALSE

Lock_name_space string

Processor_group_name string

10:25:27 SQL > show parameter spfile

NAME TYPE VALUE

Spfile string / u01/app/oracle/product/11.2.0

Ra

-

/ dbhome_1/dbs/dr1oradgphy.dat

/ dbhome_1/dbs/dr2oradgphy.dat

10:25:51 SQL > col name format A10

10:25:51 SQL > select dbid,name,current_scn,protection_mode,protection_level,database_role,force_logging,open_mode,switchover_status from v$database

D.DB_UNIQUE_NAME

D.FLASHBACK_ON

-

10:25:52 SQL > 10:25:52 2 10:25:52 3 10:25:52 4 10:25:52 5 10:25:52 6 d.FS_FAILOVER_CURRENT_TARGET

10:25:52 8 d.FS_FAILOVER_OBSERVER_PRESENT

10:25:52 10 FROM v$database d

DBID DB_UNIQUE_NAME FOR FLASHBACK_ON FS_FAILOVER_STATUS FS_FAILOVER_CURRENT_TARGET FS_FAILOVER_THRESHOLD FS_FAIL FS_FAILOVER_OBSERVER

1403587593 oradgphy YES NO DISABLED 0

Time spent: 00: 00: 00.00

Oracle 7975 10 10:21? 00:00:00 ora_dmon_oradg11g

Oracle 8463 8461 0 10:26 pts/5 00:00:00 grep dmon

10:26:07 SQL > show parameter dg_broker_start

NAME TYPE VALUE

Dg_broker_start boolean FALSE

10:26:46 SQL >! Ps-ef | grep dmon

Oracle 8481 10 10:26? 00:00:00 ora_dmon_oradgphy

Oracle 8503 8501 0 10:26 pts/5 00:00:00 grep dmon

10:26:50 SQL >

3.3.Configuring db_domain and listener and tnsnames

14:05:05 SQL > show parameter db_domain

NAME TYPE VALUE

Db_domain string

For the configuration of the master / slave library listener, note that the red one is the newly added content:

STATUS of LISTENER

Alias LISTENER

Launch date 28-September-2015 14:32:08

Trace level off

SNMP OFF

Listening Endpoint Summary.

Service summary..

Instance "+ ASM", status READY, contains 1 handler for this service.

Instance "PLSExtProc", status UNKNOWN, contains 1 handler for this service.

Instance "ora11g", status UNKNOWN, contains 1 handler for this service.

Instance "oradg11g", status UNKNOWN, contains 1 handler for this service.

Instance "oradg11g", status UNKNOWN, contains 1 handler for this service.

The service "oradg11gXDB.lhr.com" contains 2 instances.

Instance "oradgphy", status READY, contains 1 handler for this service.

Instance "oradg11g", status READY, contains 1 handler for this service.

Instance "oradg11g", status UNKNOWN, contains 1 handler for this service.

Instance "oradglg", status UNKNOWN, contains 1 handler for this service.

Instance "oradgphy", status UNKNOWN, contains 1 handler for this service.

Instance "oradgphy", status UNKNOWN, contains 1 handler for this service.

The service "oradgphy_DGB.lhr.com" contains 1 instance.

The service "oradgphy_DGMGRL.lhr.com" contains 1 instance.

The service "oradgss" contains 1 instance.

The service "orclasm.lhr.com" contains 1 instance.

Command executed successfully

# listener.ora Network Configuration File: / u01/app/grid/11.2.0/network/admin/listener.ora

(SID_LIST =

(GLOBAL_DBNAME = orclasm.lhr.com)

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

(SID_DESC =

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

)

(GLOBAL_DBNAME = oradg11g)

(SID_NAME= oradg11g)

(SID_DESC =

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

)

(GLOBAL_DBNAME = oradglg)

(SID_NAME= oradglg)

(SID_DESC =

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

)

(GLOBAL_DBNAME = ora11g)

(SID_NAME= ora11g)

(SID_DESC =

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

)

(GLOBAL_DBNAME = oradgphy.lhr.com)

(SID_NAME= oradgphy)

(SID_DESC =

(ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1)

)

(GLOBAL_DBNAME = oradgphy_DGMGRL.lhr.com)

(SID_NAME= oradgphy)

)

LOGGING_LISTENER = OFF

LISTENER =

(DESCRIPTION =

)

[oracle@rhel6_lhr admin] $

For the configuration of the master / slave library tnsnames, note that the red one is the newly added content:

# tnsnames.ora Network Configuration File: / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora

(DESCRIPTION =

(CONNECT_DATA =

(SERVICE_NAME = oradg11g_DGMGRL.lhr.com)

)

(DESCRIPTION =

(CONNECT_DATA =

(SERVICE_NAME = oradgphy_DGMGRL.lhr.com)

)

Tns_oradg11g =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.59.130) (PORT = 1521))

(SERVER = DEDICATED)

)

Tns_oradgphy =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.59.130) (PORT = 1521))

(SERVER = DEDICATED)

)

Tns_oradglg =

(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.59.130) (PORT = 1521))

(SERVER = DEDICATED)

)

DGMGRL for Linux: Version 11.2.0.3.0-64bit Production

Copyright (c) 2000, 2009, Oracle. All rights reserved.

Welcome to DGMGRL. For more information, type "help".

Connect connects to the Oracle database instance

Create create mediation configuration

Edit edits configuration, database, or instance

Exit exit program

Help displays the description and syntax of the command

Reinstate changes the database marked for recovery to a viable standby database

Remove deletes a configuration, database, or instance

Shutdown closes the currently running Oracle database instance

Start starts the quick start failover watcher

Stop stops quickly starting the failover watcher

Connected.

DGMGRL > show configuration

DGMGRL > help create

Create mediation configuration

Syntax:

CREATE CONFIGURATION AS

CONNECT IDENTIFIER IS

DGMGRL > create configuration 'fsf_oradg11g_lhr' as

> connect identifier is tns_oradg11g_dgmgrl

DGMGRL > show configuration

Configuration-fsf_oradg11g_lhr

Protection mode: MaxPerformance

Oradg11g-Master database

Quick start failover: DISABLED

Configuration status:

> connect identifier is tns_oradgphy_dgmgrl

Database "oradgphy" has been added

Database:

Oradgphy-physical standby database

Quick start failover: DISABLED

Configuration status:

Enabled.

Database:

Oradgphy-physical standby database

Quick start failover: DISABLED

Configuration status:

DGMGRL > show database verbose oradg11g

Database-oradg11g

Role: PRIMARY

Example:

DGConnectIdentifier = 'tns_oradg11g_dgmgrl'

LogXptMode = 'ASYNC'

Binding = 'OPTIONAL'

MaxConnections ='1'

NetTimeout = '30'

LogShipping = 'ON'

ApplyInstanceTimeout ='0'

StandbyFileManagement = 'AUTO'

LogArchiveMaxProcesses ='4'

DbFileNameConvert = 'oradgphy, oradg11g'

FastStartFailoverTarget =''

InconsistentLogXptProps ='(monitor)'

LogXptStatus ='(monitor)'

SidName = 'oradg11g'

StandbyArchiveLocation = 'USE_DB_RECOVERY_FILE_DEST'

LogArchiveTrace ='0'

TopWaitEvents ='(monitor)'

Database status:

Expected status: APPLY-ON

Application lag: 0 seconds

Example:

DGConnectIdentifier = 'tns_oradgphy_dgmgrl'

LogXptMode = 'ASYNC'

Binding = 'optional'

MaxConnections ='1'

NetTimeout = '30'

LogShipping = 'ON'

ApplyInstanceTimeout ='0'

StandbyFileManagement = 'AUTO'

LogArchiveMaxProcesses ='4'

DbFileNameConvert = 'oradg11g, oradgphy'

FastStartFailoverTarget =''

InconsistentLogXptProps ='(monitor)'

LogXptStatus ='(monitor)'

SidName = 'oradgphy'

StandbyArchiveLocation = 'USE_DB_RECOVERY_FILE_DEST'

LogArchiveTrace ='0'

TopWaitEvents ='(monitor)'

Database status:

DGMGRL >

Main database alarm log:

NSV1 started with pid=30, OS id=25660

ALTER SYSTEM SET log_archive_config='dg_config= (oradg11g,oradgphy) 'SCOPE=BOTH

ALTER SYSTEM SET log_archive_dest_2='service= "tns_oradgphy_dgmgrl", 'LGWR ASYNC NOAFFIRM delay=0 optional compression=disable max_failure=0 max_connections=1 reopen=300 db_unique_name= "oradgphy" net_timeout=30','valid_for= (all_logfiles,primary_role)' SCOPE=BOTH

ALTER SYSTEM SET log_archive_format='%t_%s_%r.dbf' SCOPE=SPFILE SID='oradg11g'

ALTER SYSTEM SET archive_lag_target=0 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_archive_min_succeed_dest=1 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_file_name_convert='oradgphy','oradg11g' SCOPE=SPFILE

Mon Sep 28 15:20:57 2015

Prepare the database alarm log:

Mon Sep 28 15:20:57 2015

ALTER SYSTEM SET log_archive_format='%t_%s_%r.dbf' SCOPE=SPFILE SID='oradgphy'

ALTER SYSTEM SET archive_lag_target=0 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_archive_min_succeed_dest=1 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_file_name_convert='oradg11g','oradgphy' SCOPE=SPFILE

Mon Sep 28 15:21:01 2015

RFS [4]: Assigned to RFS process 25708

After configuring broker, we can use broker to complete the switchover. In DGMGRL, you only need a simple command.

Switchover to standby-database

(standby-database: this parameter is db_unique_name and is case sensitive. If the name is capitalized, quotation marks are required. Indicates that the standby-database is switched to the host, and the original host is switched to the standby state)

Database:

Oradgphy-physical standby database

Quick start failover: DISABLED

Configuration status:

Please wait a moment to perform the switch immediately.

The operation requires that the instance "oradg11g" be closed (on the database "oradg11g")

The ORACLE routine has been closed.

Starting instance 'oradg11g'...

The database is loaded.

The switch succeeded, and the new master database is "oradgphy"

Database:

Oradg11g-physical standby database

Quick start failover: DISABLED

Configuration status:

Switch again and return to the original state:

Please wait a moment to perform the switch immediately.

The operation requires that the instance "oradgphy" be closed (on the database "oradgphy")

The ORACLE routine has been closed.

Starting instance 'oradgphy'...

The database is loaded.

The switch succeeded, and the new master database is "oradg11g"

Database:

Oradgphy-physical standby database

Quick start failover: DISABLED

Configuration status:

Main database alarm log:

ALTER DATABASE COMMIT TO SWITCHOVER TO PHYSICAL STANDBY WITH SESSION SHUTDOWN

Mon Sep 28 15:26:24 2015

Current log# 2 seq# 146 mem# 0: / u01/app/oracle/oradata/oradg11g/redo02.log

Stopping background process CJQ0

Stopping Job queue slave processes, flags = 27

Archived Log entry 501 added for thread 1 sequence 145 ID 0x5495956b dest 1:

Job queue slave processes stopped

CLOSE: killing server sessions.

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Active process 25846 user 'oracle' program' oracle@rhel6_lhr (W000)'

Waiting for all non-current ORLs to be archived...

Waiting for all FAL entries to be archived...

Waiting for dest_id 2 to become synchronized...

Switchover End-Of-Redo Log thread 1 sequence 146 has been fixed

ARCH: Noswitch archival of thread 1, sequence 146

ARCH: LGWR is actively archiving destination LOG_ARCHIVE_DEST_2

Archived Log entry 502 added for thread 1 sequence 146 ID 0x5495956b dest 1:

Primary will check for some target standby to have received alls redo

Archive destination LOG_ARCHIVE_DEST_3 invalidated

Archive destination LOG_ARCHIVE_DEST_4 invalidated

LOG_ARCHIVE_DEST_2 is a potential Physical Standby switchover target

Target has also received all redo

Clearing standby activation ID 1419089259 (0x5495956b)

'MAXLOGFILES 16 'clause.

Use the following SQL commands on the standby database to create

ALTER DATABASE ADD STANDBY LOGFILE 'srl1.f' SIZE 52428800

ALTER DATABASE ADD STANDBY LOGFILE 'srl3.f' SIZE 52428800

Archivelog for thread 1 sequence 146 required for standby recovery

Switchover: Complete-Database shutdown required

Mon Sep 28 15:26:37 2015

Shutting down instance (abort)

USER (ospid: 26018): terminating the instance

Mon Sep 28 15:26:38 2015

ORA-1092: opitsk aborting process

Starting ORACLE instance (normal)

LICENSE_SESSIONS_WARNING = 0

Archive destination LOG_ARCHIVE_DEST_3 invalidated

Archive destination LOG_ARCHIVE_DEST_4 invalidated

Autotune of undo retention is turned on.

ILAT = 27

SYS auditing is disabled

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production

ORACLE_HOME = / u01/app/oracle/product/11.2.0/dbhome_1

Node name: rhel6_lhr

Version: # 1 SMP Tue Apr 21 08:37:59 PDT 2015

VM name: VMWare Version: 6

System parameters with non-default values:

Memory_target = 300m

Control_files = "/ u01/app/oracle/oradata/oradg11g/control01.ctl"

Db_file_name_convert = "oradgphy"

Log_file_name_convert = "oradgphy"

Db_block_size = 8192

Log_archive_dest_1 = "LOCATION=USE_DB_RECOVERY_FILE_DEST db_unique_name=oradg11g valid_for= (ALL_LOGFILES,ALL_ROLES)"

Log_archive_dest_2 = "LGWR ASYNC NOAFFIRM delay=0 optional compression=disable max_failure=0 max_connections=1 reopen=300 db_unique_name=" oradgphy "net_timeout=30"

Log_archive_dest_3 = "SERVICE=tns_oradglg LGWR ASYNC db_unique_name=oradglg valid_for= (ONLINE_LOGFILES,PRIMARY_ROLE)"

Log_archive_dest_state_1 = "ENABLE"

Log_archive_dest_state_3 = "defer"

Log_archive_min_succeed_dest= 1

Fal_server = "tns_oradgphy_dgmgrl"

Log_archive_config = "dg_config= (oradg11g,oradgphy)"

Log_archive_max_processes= 4

Db_recovery_file_dest = "/ u01/app/oracle/flash_recovery_area"

Standby_file_management = "AUTO"

Remote_login_passwordfile= "EXCLUSIVE"

Global_names = TRUE

Audit_file_dest = "/ u01/app/oracle/admin/oradg11g/adump"

Db_name = "oradg11g"

Open_cursors = 300

Diagnostic_dest = "/ u01/app/oracle"

PMON started with pid=2, OS id=26102

PSP0 started with pid=3, OS id=26104

Using STANDBY_ARCHIVE_DEST parameter default value as USE_DB_RECOVERY_FILE_DEST

Mon Sep 28 15:26:39 2015

VKTM running at (1) millisec precision with DBRM quantum (100) ms

GEN0 started with pid=5, OS id=26116

DIAG started with pid=6, OS id=26118

DBRM started with pid=7, OS id=26120

DIA0 started with pid=8, OS id=26122

MMAN started with pid=9, OS id=26124

DBW0 started with pid=10, OS id=26126

LGWR started with pid=11, OS id=26128

CKPT started with pid=12, OS id=26130

SMON started with pid=13, OS id=26132

RECO started with pid=14, OS id=26134

MMON started with pid=15, OS id=26136

MMNL started with pid=16, OS id=26138

Starting up 1 shared server (s)...

Mon Sep 28 15:26:40 2015

Mon Sep 28 15:26:40 2015

ARCH: STARTING ARCH PROCESSES

ARC0 started with pid=22, OS id=26157

ARCH: STARTING ARCH PROCESSES COMPLETE

Successful mount of redo thread 1, with mount id 1419115888

Starting background process RVWR

ARC1 started with pid=23, OS id=26159

RVWR started with pid=24, OS id=26161

ARC2 started with pid=25, OS id=26163

ARC3 started with pid=26, OS id=26165

ARC2: Archival started

ARC1: Becoming the'no SRL' ARCH

Physical Standby Database mounted.

ARC2: Becoming the active heartbeat ARCH

Alter database open

Data Guard Broker initialization complete

Beginning standby crash recovery.

Managed Standby Recovery starting Real Time Apply

Media Recovery Log / u01/app/oracle/flash_recovery_area/ORADG11G/archivelog/2015_09_28/o1_mf_1_146_c0ktx6mn_.arc

Resetting standby activation ID 0 (0x0)

Completed standby crash recovery.

Mon Sep 28 15:26:46 2015

RFS [1]: Opened log for thread 1 sequence 148 dbid 1403587593 branch 886695024

Dictionary check beginning

RFS [2]: Assigned to RFS process 26179

Archived Log entry 505 added for thread 1 sequence 147 rlc 886695024 ID 0x54960fb7 dest 2:

Database Characterset is ZHS16GBK

Replication_dependency_tracking turned off (no async multimaster replication found)

RFS [2]: Selected log 4 for thread 1 sequence 149 dbid 1403587593 branch 886695024

Archived Log entry 506 added for thread 1 sequence 149 ID 0x54960fb7 dest 1:

Db_recovery_file_dest_size of 4122 MB is 6.96% used. This is a

Database for recovery-related files, and does not reflect the amount of

Mon Sep 28 15:26:46 2015

RFS [3]: Assigned to RFS process 26185

ARC3: Archival started

Starting Data Guard Broker (DMON)

INSV started with pid=30, OS id=26191

NSV1 started with pid=31, OS id=26199

RSM0 started with pid=32, OS id=26208

ALTER SYSTEM SET log_archive_trace=0 SCOPE=BOTH SID='oradg11g'

ALTER SYSTEM SET standby_file_management='AUTO' SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_archive_max_processes=4 SCOPE=BOTH SID='*'

ALTER SYSTEM SET db_file_name_convert='oradgphy','oradg11g' SCOPE=SPFILE

ALTER SYSTEM SET fal_server='tns_oradgphy_dgmgrl' SCOPE=BOTH

Attempt to start background Managed Standby Recovery process (oradg11g)

MRP0 started with pid=33, OS id=26214

Started logmerger process

Managed Standby Recovery starting Real Time Apply

Waiting for all non-current ORLs to be archived...

Clearing online redo logfile 1/ u01/app/oracle/oradata/oradg11g/redo01.log

Clearing online redo logfile 1 complete

Clearing online log 2 of thread 1 sequence number 146

Completed: ALTER DATABASE RECOVER MANAGED STANDBY DATABASE THROUGH ALL SWITCHOVER DISCONNECT USING CURRENT LOGFILE

Clearing online redo logfile 3 / u01/app/oracle/oradata/oradg11g/redo03.log

Clearing online redo logfile 3 complete

RFS [3]: Selected log 5 for thread 1 sequence 151 dbid 1403587593 branch 886695024

Archived Log entry 507 added for thread 1 sequence 150 ID 0x54960fb7 dest 1:

Media Recovery Log / u01/app/oracle/flash_recovery_area/ORADG11G/archivelog/2015_09_28/o1_mf_1_148_c0ktxp70_.arc

Media Recovery Log / u01/app/oracle/flash_recovery_area/ORADG11G/archivelog/2015_09_28/o1_mf_1_150_c0ktycgh_.arc

Recovery of Online Redo Log: Thread 1 Group 5 Seq 151 Reading mem 0

Mon Sep 28 15:26:24 2015

Mon Sep 28 15:26:24 2015

Mon Sep 28 15:26:30 2015

RFS [6]: Selected log 4 for thread 1 sequence 146 dbid 1403587593 branch 886695024

Archived Log entry 129 added for thread 1 sequence 146 ID 0x5495956b dest 1:

ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL

Errors in file / u01/app/oracle/diag/rdbms/oradgphy/oradgphy/trace/oradgphy_pr00_24252.trc:

Managed Standby Recovery not using Real Time Apply

Mon Sep 28 15:26:31 2015

Managed Standby Recovery Canceled (oradgphy)

Database not available for switchover

Incomplete recovery SCN:0:2481770 archive SCN:0:2501780

Media Recovery Start: Managed Standby Recovery (oradgphy)

Mon Sep 28 15:26:32 2015

Parallel Media Recovery started with 2 slaves

Identified End-Of-Redo (switchover) for thread 1 sequence 146at SCN 0x0.262c94

Media Recovery End-Of-Redo indicator encountered

Media Recovery Complete: End-Of-REDO (oradgphy)

Completed: ALTER DATABASE RECOVER MANAGED STANDBY DATABASE THROUGH LAST SWITCHOVER NODELAY

ALTER DATABASE SWITCHOVER TO PRIMARY (oradgphy)

Krsv_proc_kill: Killing 2 processes (all RFS)

CLOSE: killing server sessions.

Mon Sep 28 15:26:34 2015

Backup controlfile written to trace file / u01/app/oracle/diag/rdbms/oradgphy/oradgphy/trace/oradgphy_rsm0_24244.trc

Online log / u01/app/oracle/oradata/oradgphy/redo01.log: Thread 1 Group 1 was previously cleared

Online log / u01/app/oracle/oradata/oradgphy/redo03.log: Thread 1 Group 3 was previously cleared

AUDIT_TRAIL initialization parameter is changed back to its original value as specified in the parameter file.

Completed: ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY WAIT WITH SESSION SHUTDOWN

Idle dispatcher 'D000' terminated, pid = (17,1)

Data Guard Broker initializing...

Assigning activation ID 1419120567 (0x54960fb7)

ARC3: Becoming the'no SRL' ARCH

ARC0: Becoming the'no SRL' ARCH

Current log# 2 seq# 148 mem# 0: / u01/app/oracle/oradata/oradgphy/redo02.log

MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set

Archived Log entry 130 added for thread 1 sequence 147 ID 0x54960fb7 dest 1:

Mon Sep 28 15:26:37 2015

Mon Sep 28 15:26:37 2015

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGMGRL.lhr.com) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12537

*

Fatal NI connect error 12537, connecting to:

TNS for Linux: Version 11.2.0.3.0-Production

Time: 28-SEP-2015 15:26:37

Tns error struct:

Undo initialization finished serial:0 start:21508174 end:21508224 diff:50 (0 seconds)

TNS-12537: TNS:connection closed

Ns secondary err code: 12560

Ns secondary err code: 12560

Nt main err code: 507

Nt secondary err code: 0

Nt OS err code: 0

Nt secondary err code: 0

*

Fatal NI connect error 12537, connecting to:

TNS for Linux: Version 11.2.0.3.0-Production

Time: 28-SEP-2015 15:26:37

Tns error struct:

Ns secondary err code: 12560

Nt secondary err code: 0

Dictionary check complete

Verifying 11g file header compatibility for tablespace encryption completed

Database Characterset is ZHS16GBK

*

Fatal NI connect error 12537, connecting to:

TNS for Linux: Version 11.2.0.3.0-Production

Time: 28-SEP-2015 15:26:37

Tns error struct:

Ns secondary err code: 12560

Nt secondary err code: 0

*

Fatal NI connect error 12537, connecting to:

TNS for Linux: Version 11.2.0.3.0-Production

Time: 28-SEP-2015 15:26:37

Tns error struct:

Ns secondary err code: 12560

Nt secondary err code: 0

Error 12537 received logging on to the standby

FAL [server, ARC3]: FAL archive failed, see trace file.

ORACLE Instance oradgphy-Archival Error. Archiver continuing.

SMCO started with pid=26, OS id=26033

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGMGRL.lhr.com) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12537

TNS-12537: TNS:connection closed

Nt main err code: 507

TNS-00507: Connection closed

Nt OS err code: 0

PING [ARC2]: Heartbeat failed to connect to standby 'tns_oradg11g_dgmgrl'. Error is 12537.

Starting background process QMNC

QMNC started with pid=27, OS id=26036

LOGSTDBY: Validation complete

ALTER SYSTEM SET log_archive_trace=0 SCOPE=BOTH SID='oradgphy'

Starting background process CJQ0

CJQ0 started with pid=32, OS id=26050

ALTER SYSTEM SET archive_lag_target=0 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_archive_min_succeed_dest=1 SCOPE=BOTH SID='*'

ALTER SYSTEM SET log_file_name_convert='oradg11g','oradgphy' SCOPE=SPFILE

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE' SCOPE=BOTH

Mon Sep 28 15:26:38 2015

ARC4: Archival started

PING [ARC2]: Heartbeat failed to connect to standby 'tns_oradg11g_dgmgrl'. Error is 16058.

Current log# 3 seq# 149 mem# 0: / u01/app/oracle/oradata/oradgphy/redo03.log

Mon Sep 28 15:26:41 2015

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (INSTANCE_NAME=oradg11g) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (INSTANCE_NAME=oradg11g) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (INSTANCE_NAME=oradg11g) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=192.168.59.130) (PORT=1521)) (CONNECT_DATA= (SERVER=DEDICATED) (SERVICE_NAME=oradg11g_DGB.lhr.com) (CID= (PROGRAM=oracle) (HOST=rhel6_lhr) (USER=grid)

VERSION INFORMATION:

TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0-Production

Tracing not turned on.

Ns main err code: 12564

TNS-12564: TNS:connection refused

Nt main err code: 0

Nt OS err code: 0

Mon Sep 28 15:26:44 2015

Shutting down archive processes

ARC4: Archival stopped

ALTER SYSTEM SET log_archive_dest_state_2='ENABLE' SCOPE=MEMORY SID='*'

ARC3: Becoming the'no SRL' ARCH

Current log# 1 seq# 150 mem# 0: / u01/app/oracle/oradata/oradgphy/redo01.log

Archived Log entry 134 added for thread 1 sequence 149 ID 0x54960fb7 dest 1:

ARC0: Standby redo logfile selected for thread 1 sequence 149 for destination LOG_ARCHIVE_DEST_2

LGWR: Setting 'active' archival for destination LOG_ARCHIVE_DEST_2

LNS: Standby redo logfile selected for thread 1 sequence 150 for destination LOG_ARCHIVE_DEST_2

ALTER SYSTEM ARCHIVE LOG

Thread 1 cannot allocate new log, sequence 151

Current log# 1 seq# 150 mem# 0: / u01/app/oracle/oradata/oradgphy/redo01.log

ARC3: Becoming the'no SRL' ARCH

Current log# 2 seq# 151 mem# 0: / u01/app/oracle/oradata/oradgphy/redo02.log

Mon Sep 28 15:27:07 2015

Thank you for reading this article carefully. I hope the article "how to configure Dataguard Broker in Oracle physical DG automatic switching" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report