Wednesday, 25 May 2016

How to disable and enable logshipping when your standby database is in maximum availabilty through DataGuard Broker Architecture.


   We may not be able to disable the logtransport when the database is in maximum availabilty mode. We may get the below error




DGMGRL> edit database 'DBNAME' set state=TRANSPORT-OFF;

Error: ORA-16627: operation disallowed since no standby databases would remain to support protection mode
 We may need to transfer the mode to maximum performance and disable the log transport.
Disable Logshipping
   1.1. Connect to dgmgrl broker
            dgmgrl
                 connect /
  1.2  Verify the protection mode
  DGMGRL> show configuration
 Configuration - DBNAME
   Protection Mode: MaxAvailability
   Databases:
     DBNAME    - Primary database
     DBNAME_SB - Physical standby database
 Fast-Start Failover: DISABLED
 Configuration Status:
 SUCCESS
 1.3 Disable the log apply in standby database
    EDIT DATABASE 'DBNAME_SB' SET STATE='APPLY-OFF';  
 1.4 Convert the database into maximum performance mode
   EDIT CONFIGURATION SET PROTECTION MODE AS MAXPERFORMANCE;
    
  1.5  Verify the configutaion
 DGMGRL> show configuration
 Configuration - DBNAME
   Protection Mode: MaxPerformance
   Databases:
     DBNAME    - Primary database
     DBNAME_SB - Physical standby database
 Fast-Start Failover: DISABLED
 Configuration Status:
 SUCCESS
 1.6  Disable to the log transport
      edit database 'DBNAME' set state='LOG-TRANSPORT-OFF';
 1.7 Verify the configuration in verbose mode
       show database verbose 'DBNAME'
      Database - DBNAME
   Role:            PRIMARY
   Intended State:  TRANSPORT-OFF
   Instance(s):
    .....
Enable Logshipping
 1.1 EDIT DATABASE 'DBNAME_SB' SET STATE='APPLY-ON';
 1.2 EDIT DATABASE 'DBNAME'  SET STATE='TRANSPORT-ON';
 1.3 EDIT CONFIGURATION SET PROTECTION MODE AS  'MAXAVAILABILITY'

   

No comments:

Post a Comment

ZFS

Public Cloud tools comparison