SWITCHOVER ERROR: Switchover target couldn't convert to primary database due to error 1275

alter database switchover to TSTSBY
Mon Apr 08 12:04:40 2019
Starting switchover [Process ID: 19008]
Mon Apr 08 12:04:40 2019


SWITCHOVER ERROR: Switchover target couldn't convert to  primary database due to error 1275.
Check switchover target's alert log for detailed error.
USER (ospid: 19008): terminating the instance
Mon Apr 08 12:05:53 2019
Instance terminated by USER, pid = 19008
ORA-16471 signalled during: alter database switchover to TSTSBY.

SQL> SELECT database_role role, name,dbid, db_unique_name, platform_id, open_mode, log_mode, flashback_on, protection_mode, protection_level FROM v$database;

ROLE             NAME            DBID DB_UNIQUE_NAME                 PLATFORM_ID
---------------- --------- ---------- ------------------------------ -----------
OPEN_MODE            LOG_MODE     FLASHBACK_ON       PROTECTION_MODE
-------------------- ------------ ------------------ --------------------
PROTECTION_LEVEL
--------------------
PHYSICAL STANDBY TSTDB     3526761822 TSTDB                                   13
READ ONLY            ARCHIVELOG   YES                MAXIMUM PERFORMANCE
MAXIMUM PERFORMANCE


SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit

Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Advanced Analytics and Real Application Testing options

SQL> SELECT database_role role, name,dbid, db_unique_name, platform_id, open_mode, log_mode, flashback_on, protection_mode, protection_level FROM v$database;

ROLE             NAME            DBID DB_UNIQUE_NAME                 PLATFORM_ID
---------------- --------- ---------- ------------------------------ -----------
OPEN_MODE            LOG_MODE     FLASHBACK_ON       PROTECTION_MODE
-------------------- ------------ ------------------ --------------------
PROTECTION_LEVEL
--------------------
PHYSICAL STANDBY TSTDB     3526761822 TSTDB                                   13
READ ONLY            ARCHIVELOG   YES                MAXIMUM PERFORMANCE
MAXIMUM PERFORMANCE


SQL> select db_unique_name,open_mode,database_role from gv$database;

DB_UNIQUE_NAME                 OPEN_MODE            DATABASE_ROLE
------------------------------ -------------------- ----------------
TSTDB                          READ ONLY            PHYSICAL STANDBY

SQL> select switchover_status from v$database;

SWITCHOVER_STATUS
--------------------
TO PRIMARY

SQL> alter database commit to switchover to primary;

Database altered.

SQL> shut immediate
ORA-01109: database not open


Database dismounted.
ORACLE instance shut down.
SQL> startup mount;
ORACLE instance started.

Total System Global Area 1.0737E+10 bytes
Fixed Size                  6081440 bytes
Variable Size            7818183776 bytes
Database Buffers         2885681152 bytes
Redo Buffers               27471872 bytes
Database mounted.
SQL> select db_unique_name,open_mode,database_role from gv$database;

DB_UNIQUE_NAME                 OPEN_MODE            DATABASE_ROLE
------------------------------ -------------------- ----------------
TSTDB                          MOUNTED              PRIMARY

SQL> alter database open;

Database altered.

SQL> select db_unique_name,open_mode,database_role from gv$database;

DB_UNIQUE_NAME                 OPEN_MODE            DATABASE_ROLE
------------------------------ -------------------- ----------------
TSTDB                          READ WRITE           PRIMARY

SQL>

Comments

Popular posts from this blog

QUERY DATAGUARD AND STANDBY STATUS

Blocking session on RAC database

Finding object size in Oracle database