Time for action – disabling and enabling database

Follow these steps to test disabling and enabling the standby database:

  1. Check the status of the standby database as follows:
    DGMGRL> show database 'INDIA_UN';
    Database - INDIA_UN
      Role:            PHYSICAL STANDBY
      Intended State:  APPLY-ON
      Transport Lag:   0 seconds
      Apply Lag:       0 seconds
      Real Time Query: ON
      Instance(s):
        INDIA
    Database Status:
    SUCCESS
    
  2. Disable the database from the configuration as follows:
    DGMGRL> disable database 'INDIA_UN';
    Disabled.
    
  3. Check the database status after disabling it from the configuration as follows:
    DGMGRL> show database 'INDIA_UN';
    Database - INDIA_UN
      Role:            PHYSICAL STANDBY
      Intended State:  APPLY-ON
      Transport Lag:   (unknown)
      Apply Lag:       (unknown)
      Real Time Query: OFF
      Instance(s):
        INDIA
    Database Status:
    DISABLED
    
  4. Physical standby information still exists in the configuration, but the database will be in a DISABLED state and won't be monitored by the broker. However, the configuration status will be SUCCESS.
  5. Now enable the database to the broker configuration as follows:
    DGMGRL> enable database 'INDIA_UN';
    Enabled.
    
  6. After enabling the database, the Data Guard broker instance slave process will be started at the standby database name mentioned in the command. Implicitly, a log switch will occur in order to synchronize the environments.
  7. Check the final database status as follows:
    DGMGRL> show database 'INDIA_UN';
    Database - INDIA_UN
      Role:            PHYSICAL STANDBY
      Intended State:  APPLY-ON
      Transport Lag:   0 seconds
      Apply Lag:       0 seconds
      Real Time Query: ON
      Instance(s):
        INDIA
    Database Status:
    SUCCESS
    

Now the database is enabled and is part of the broker configuration again.

What just happened?

We've learned how to disable and enable Data Guard broker management completely, and how to disable and enable only a standby database of the configuration.

Changing configuration and database properties using broker

After the creation of the Data Guard configuration using DGMGRL, you can edit the configuration or single database properties. The following command is an example of a configuration change that changes the fast-start failover threshold value to 60 seconds. This command can be run either from the primary or the standby database:

DGMGRL> show configuration 'FastStartFailoverThreshold';
  FastStartFailoverThreshold = '30'
DGMGRL> edit configuration set property FastStartFailoverThreshold=60;
Property "faststartfailoverthreshold" updated
DGMGRL> show configuration 'FastStartFailoverThreshold';
  FastStartFailoverThreshold = '60'

These changes will be updated in all the configuration files.

On the other hand, database property changes are specific to either the primary or a standby database. It won't perform changes in the rest of the configuration. In case it's a clustered database, these changes will be applicable for all of the instances of that database. An example to change the archive log tracing level to 10 in the standby database only is as follows:

DGMGRL> show database 'INDIA_UN' 'LogArchiveTrace';
  LogArchiveTrace = '0'
DGMGRL>  edit database 'INDIA_UN' SET PROPERTY LogArchiveTrace=10;
Property "logarchivetrace" updated
DGMGRL> show database 'INDIA_UN' 'LogArchiveTrace';
  LogArchiveTrace = '10'

Have a go hero – more examples on property changes

Now it's your turn to try changing some database properties. You can practice with the following parameters by monitoring, changing, and restoring their values as follows:

DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY 'LogArchiveFormat'= 'log_%t_%s_%r_%d.arc';DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY LogXptMode=SYNC;
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY LogShipping=OFF;
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY NetTimeout=30;
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY 'ReopenSecs'=400;
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY ArchiveLagTarget=800;
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY 'DbFileNameConvert' = '/u01/app/oracle/oradata/orcl/, /u02/app/oracle/oradata/orcl/';
DGMGRL> EDIT DATABASE 'INDIA_UN' SET PROPERTY DelayMins='540';
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.118.20.90