Failover switching of Oracle RAC Environment logical Standby

Source: Internet
Author: User
Tags failover

The primary database and the standby database are all RAC 11.1.0.6 for Solaris10 SPARC, the shared storage primary database takes Volumn CLUSTER MANAGER, and the standby database uses ASM.

Failover switch is used when the main library is unavailable.

This is relatively simple and does not require much preparation, but for impersonation, the primary database is first closed:

Sql> Select instance_name, status from Gv$instance;

instance_name STATUS

---------------- ------------

RAC11G1 OPEN

Rac11g2 OPEN

Sql> select Name,

2 Open_mode,

3 Database_role,

4 Guard_status,

5 Db_unique_name,

6 Primary_db_unique_name

7 from V$database;

NAME open_mode database_role guard_s db_unique_name primary_db_unique_name

--------- ---------- ---------------- ------- --------------- -------------------------

rac11g_l READ WRITE PRIMARY NONE rac11g_s rac11g

sql> shutdown Immediate

The database has been closed.

The database has been unloaded.

The Oracle routine has been closed.

The following closes instance 2:

Sql> select instance_name from Gv$instance;

Instance_name

----------------

Rac11g2

sql> shutdown Immediate

The database has been closed.

The database has been unloaded.

The Oracle routine has been closed.

The 2nd instance of logical standby is closed below:

Sql> Select instance_name, status from Gv$instance;

instance_name STATUS

---------------- ------------

Rac11g2 OPEN

RAC11G1 OPEN

Sql> select Name,

2 Open_mode,

3 Database_role,

4 Guard_status,

5 Db_unique_name,

6 Primary_db_unique_name

7 from V$database;

This article URL address: http://www.bianceng.cn/database/Oracle/201410/45385.htm

NAME open_mode database_role guard_s db_unique_name primary_db_unique_name

--------- ---------- ---------------- ------- --------------- -------------------------

rac11g READ WRITE LOGICAL STANDBY all rac11g rac11g_s

sql> shutdown Immediate

The database has been closed.

The database has been unloaded.

The Oracle routine has been closed.

Check Instance 1:

Sql> Select instance_name, status from Gv$instance;

instance_name STATUS

---------------- ------------

RAC11G1 OPEN

If an updated archive log can be found, it can be copied to the local database and registered through ALTER DATABASE register LOGICAL logfile.

The logical standby database is switched to the main database below:

Sql> Select instance_name, status from Gv$instance;

instance_name STATUS

---------------- ------------

RAC11G1 OPEN

Sql> ALTER DATABASE activate logical standby database;

The database has changed.

Sql> select Name,

2 Open_mode,

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.