Oracle 11.2.0.4.0 Dataguard Deployment and routine maintenance (5)-datauard Primary and Standby switchover and failover chapter

Source: Internet
Author: User
Tags failover

1. Dataguard Primary and Standby switching

1.1. Check if the current master repository has switching conditions

    • On slave
SelectSequence#,first_time,next_time,archived,applied fromV$archived_logwheresequence#=(Select Max(sequence#) fromV$archived_log); sequence# first_time next_time Archived applied------------------------------------------------------------------------------------    Wuyi        .- --Geneva  A:xx: A       .- --Geneva  -:Geneva: -YESin-MEMORYSelectSequence#,first_time,next_time,archived,applied fromV$archived_logwheresequence#=(Select Max(sequence#) fromV$archived_log); sequence# first_time next_time Archived applied---------- ------------------- ------------------- --------- ---------------------------    Wuyi  .- --Geneva  A:xx: A  .- --Geneva  -:Geneva: -YESin-MEMORYSelectProcess,sequence#,status fromV$managed_standby; PROCESS sequence# STATUS--------------------------- ---------- ------------------------------------ARCH -Closingarch -Closingarch0ConnectedarchWuyiClosingrfs0Idlerfs theIdlerfs0IDLEMRP0 theApplying_log

    • On Master
SelectSequence#,status fromv$Log Order  bysequence#; sequence# STATUS---------- ------------------------------------------------     -INACTIVEWuyiINACTIVE the        Currentcolumndatabase_role Format A20columnopen_mode Format A15columnprotection_mode Format A20columnswitchover_status Format A20SelectDatabase_role,open_mode,protection_mode,switchover_status fromv$Database;D atabase_role open_mode protection_mode switchover_status-------------------- --------------- -------------------- --------------------PRIMARY                READWRITE MAXIMUM Performance toSTANDBY

1.2. Converting the main library to a standby library

Alter Database Commit  toSwitchover toPhysical standby withSessionshutdown; startup Mount;Alter DatabaseRecover managed StandbyDatabaseUsing CurrentLogFile Disconnect fromsession;SelectDatabase_role,open_mode,protection_mode,switchover_status fromv$Database;D atabase_role open_mode protection_mode switchover_status-------------------- --------------- -------------------- --------------------Physical STANDBY mounted MAXIMUM performance to PRIMARY

1.3. Converting a standby library to a master library

columndatabase_role Format A20columnopen_mode Format A15columnprotection_mode Format A20columnswitchover_status Format A20SelectDatabase_role,open_mode,protection_mode,switchover_status fromv$Database;D atabase_role open_mode protection_mode switchover_status-------------------- --------------- -------------------- --------------------Physical STANDBY mounted MAXIMUM performance to PRIMARYAlter Database Commit  toSwitchover to Primary;Alter Database Open;SelectDatabase_role,open_mode,protection_mode,switchover_status fromv$Database;D atabase_role open_mode protection_mode switchover_status-------------------- --------------- -------------------- --------------------PRIMARY              READWRITE MAXIMUM Performance toSTANDBY

1.4. Test the primary and standby data synchronization status

    • On primary
SelectSequence#,first_time,next_time,archived,applied fromV$archived_logwheresequence#=(Select Max(sequence#) fromV$archived_log); sequence# first_time next_time Archived applied---------- ------------------- ------------------- --------- ---------------------------     Wu      .- -- to  Geneva: -: the  .- -- to  Geneva: -: +YES NO Wu      .- -- to  Geneva: -: the  .- -- to  Geneva: -: +Yes YesAlterSystem ArchiveLog  Current;AlterSystem ArchiveLog  Current;SelectSequence#,first_time,next_time,archived,applied fromV$archived_logwheresequence#=(Select Max(sequence#) fromV$archived_log); sequence# first_time next_time Archived applied---------- ------------------- ------------------- --------- ---------------------------     About      .- -- to  Geneva: +: on   .- -- to  Geneva: +:GenevaYES NO About      .- -- to  Geneva: +: on   .- -- to  Geneva: +:GenevaYES NO

    • On standby
SelectSequence#,first_time,next_time,archived,applied fromV$archived_logwheresequence#=(Select Max(sequence#) fromV$archived_log); sequence# first_time next_time Archived applied---------- ------------------- ------------------- --------- ---------------------------     About      .- -- to  Geneva: +: on  .- -- to  Geneva: +:GenevaYESin-MEMORY

2. Dataguard failover

2.1. Premise: The main library has been hung off

2.2. Casting the repository to the master library

2.3. Rebuilding the Standby Library

Oracle 11.2.0.4.0 Dataguard Deployment and routine maintenance (5)-datauard Primary and Standby switchover and failover chapter

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.