Thursday, May 28, 2020

How to start and stop dataguard sync using dgmgrl

How to start and stop dataguard sync using dgmgrl


To check the configuration:

DGMGRL> show configuration
Configuration - dell
Protection Mode: MaxPerformance
Databases:
dell_live - Primary database
dell_stby - Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
SUCCESS

To check the primary database status:

DGMGRL> show database dell_live
Database - dell_live
Role:            PRIMARY
Intended State:  TRANSPORT-ON
Instance(s):
DELL
Database Status:
SUCCESS

To check the standby database status:

DGMGRL> show database dell_stby
Database - dell_stby
Role:            PHYSICAL STANDBY
Intended State:  APPLY-ON
Transport Lag:   0 seconds
Apply Lag:       0 seconds
Real Time Query: OFF
Instance(s):
DELL
Database Status:
SUCCESS

To stop the database sync:

DGMGRL> edit database dell_stby set state=apply-off;
Succeeded.
DGMGRL> show database dell_stby
Database - dell_stby
Role:            PHYSICAL STANDBY
Intended State:  APPLY-OFF
Transport Lag:   0 seconds
Apply Lag:       0 seconds
Real Time Query: OFF
Instance(s):
DELL
Database Status:
SUCCESS

To start the database sync:

DGMGRL> edit database dell_stby set state=apply-on;
Succeeded.

To check the primary database status:

DGMGRL> show database dell_live
Database - dell_live
Role:            PRIMARY
Intended State:  TRANSPORT-ON
Instance(s):
DELL
Database Status:
SUCCESS

To check the standby database status:

DGMGRL> show database dell_stby;
Database - dell_stby
Role:            PHYSICAL STANDBY
Intended State:  READ-ONLY
Transport Lag:   0 seconds
Apply Lag:       3 minutes 10 seconds
Real Time Query: OFF
Instance(s):
DELL
Database Status:
SUCCESS


No comments:

Post a Comment