RAC with single-instance DG switching test
I. Overview of the Environment
1, Environment
Orace rac& Single Instance DG
Os:centos - 5.8
oracle:10.2.0.4
2,DGSynchronization Status
Rac1:
650) this.width=650; "width=" 389 "height=" "src=" http://s3.51cto.com/wyfs02/M02/57/63/ Wkiol1szlmgxvy6taacpln5rwrc392.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164654.png "/>
Dg:
650) this.width=650; "Width=" 459 "height=" "src=" http://s3.51cto.com/wyfs02/M00/57/63/ Wkiol1szlnbblgraaacpiozbuug425.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164712.png "/>
DG is now in sync State
3, archive situation
Rac
650) this.width=650; "Width=" 409 "height=" 167 "src=" http://s3.51cto.com/wyfs02/M01/57/66/ Wkiom1szleui70psaae2kyp6kjq124.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164718.png "/>
650) this.width=650; "Width=" 407 "height=" 147 "src=" http://s3.51cto.com/wyfs02/M02/57/63/ Wkiol1szlqoi9u5-aafa5gpzmzy435.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164727.png "/>
Dg:
650) this.width=650; "width=" 406 "height=" 147 "src=" http://s3.51cto.com/wyfs02/M02/57/66/ Wkiom1szlhggfsv1aaejzyz-4im500.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164750.png "/>
Second,RAC cutting,DG cutting master, switch test
1,Rac1&rac2Manually Cut Archives
Rac1:
alter system switch logfile; performed two times two times interval 30s
RAC2:
alter system switch logfile; performed two times two times interval 30s
2, check the archive between two libraries
Rac:
Thread 1:
650) this.width=650; "Width=" 418 "height=" 279 "src=" http://s3.51cto.com/wyfs02/M00/57/63/ Wkiol1szlsuhh3h-aafgclyvd4y892.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164754.png "/>
Thread 2:
650) this.width=650, "width=" 421 "height=" "src=" Http://s3.51cto.com/wyfs02/M00/57/66/wKiom1SZLi7wwPc4AAFGSjk_ Epo292.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid # DDD; "alt=" Spacer.gif "title=" qq picture 20141223164800.png "/>
Dg:
650) this.width=650; "Width=" 410 "height=" 273 "src=" http://s3.51cto.com/wyfs02/M01/57/63/ Wkiol1szlu6ify4caafkex4eply831.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164807.png "/>
3, ready to switch jobs
Turn off the RAC Library and turn the Rac1 to Open
Rac1&rac2
Shutdown immediate;
Rac1
startup Open;
4, start switching (execution time80saround)
ALTER DATABASE COMMIT to switchover tophysical STANDBY with SESSION SHUTDOWN;
when the command finishes , view the database status
650) this.width=650; "Width=" 281 "height=" "src=" http://s3.51cto.com/wyfs02/M01/57/66/ Wkiom1szllii7hp3aaascwgz4ik754.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164813.png "/>
At this point, for Nomount Status
When using alterdatabase mount to mount the library
650) this.width=650; "width=" 303 "height=" "src=" http://s3.51cto.com/wyfs02/M00/57/63/ Wkiol1szlw-ysgrxaabcwoj26hm612.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164819.png "/>
Restart database to Mount
Shutdownimmediate;
Startupmount;
View database Roles and status
650) this.width=650; "width=" 419 "height=" 186 "src=" http://s3.51cto.com/wyfs02/M00/57/66/ Wkiom1szlnasxbs5aabjmoqnhqi709.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164826.png "/>
at this Main Library Rac1 has become a standby library
DG Switch to main library (1s execution complete)
Alterdatabase COMMIT to switchover to PRIMARY with SESSION SHUTDOWN;
View DG Library Status
650) this.width=650; "Width=" 397 "height=" "src=" http://s3.51cto.com/wyfs02/M01/57/63/ Wkiol1szlzdgu1rdaaa5m5nt-pa007.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164830.png "/>
DG switch to Main library, database status is mount , put the library into open status (Execution Time 8s)
Alterdatabase Open;
RAC Automatic recovery of library (3s execution complete)
Recover managed Standby Database Disconnectfrom session;
5, the new archive application of the main repository
New Main Library (DG)
650) this.width=650; "Width=" 414 "height=" 370 "src=" http://s3.51cto.com/wyfs02/M02/57/63/ Wkiol1szl0jstadyaahkn7cs-uu807.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164835.png "/>
RAC :
650) this.width=650; "width=" 406 "height=" 412 "src=" Http://s3.51cto.com/wyfs02/M02/57/66/wKiom1SZLqyw9407AAIQSJrXO _c991.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd ; "alt=" Spacer.gif "title=" qq picture 20141223164954.png "/>
manually cut the archive two times on the new Main library (DG)
alter system switch logfile;
Review the archive between the two libraries again
New Main Library (DG)
650) this.width=650; "Width=" 465 "height=" 291 "src=" http://s3.51cto.com/wyfs02/M00/57/63/ Wkiol1szl2orrbbhaaf6qugiv4o350.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164959.png "/>
RAC Library:
650) this.width=650; "Width=" 469 "height=" 345 "src=" http://s3.51cto.com/wyfs02/M00/57/66/ Wkiom1szlsrss8muaaf6qugiv4o099.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223164959.png "/>
This allows the new primary and standby relationships to be normal.
three, DG Cutting,RAC cutting master, switch test
1, new Main library (DG)cut to standby (execution time60saround)
Dg:
ALTER DATABASE COMMIT to switchover tophysical STANDBY with SESSION SHUTDOWN;
after performing the switchover, the database is nomount State and the library is restarted to the Mount state
Shutdown immediate;
startup Mount;
View DG database roles for libraries
650) this.width=650; "width=" 389 "height=" "src=" http://s3.51cto.com/wyfs02/M01/57/63/ Wkiol1szl4fj1a6waaa-1h-ufz0801.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223165007.png "/>
2,RACLibrary cut to main library(Execution Time1s)
ALTER DATABASE COMMIT to switchover toprimary with SESSION SHUTDOWN;
View the database role and start the database to open Status
650) this.width=650; "Width=" 402 "height=" 164 "src=" http://s3.51cto.com/wyfs02/M01/57/66/ Wkiom1szluns0tptaabjgb7kr6g707.jpg "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "title=" qq picture 20141223165010.png "/>
Switch is complete.
will Rac2 Library Open
startup Open;
This article is from the "Li_weikang" blog, make sure to keep this source http://liweikang.blog.51cto.com/3246878/1593926
Oracle RAC vs. single-instance DG switching test