Data Guard - Changing IP Addresses

When changing IP of a host we should update/recheck the following places:
  1. /etc/hosts or DNS
  2. listener.ora
  3. tnsnames.ora
  4. Database parameters (local_listener, remote_listener)
  5. Data Guard configuration
This document is also relevant when changing the IP address of the connection between the hosts, other than the original IP addresses we used during the installation.
When installation is done using the hostname and not the IP address, most of the changes are not relevant except for /etc/hosts.

In this document, I will describe how to change the Data Guard Broker configuration.
Dataguard configuration

Show the environment
DGMGRL> show configuration

Configuration - dr

  Protection Mode: MaxAvailability
  Members:
  pdb7 - Primary database
    fdb7 - Far sync instance
      sdb7 - Physical standby database

Fast-Start Failover: DISABLED

Configuration Status:
SUCCESS   (status updated 351 seconds ago)
Show detailed information of the Primary
DGMGRL> show database pdb7 StaticConnectIdentifier

  StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.15.1.60)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=pdb7_DGMGRL)(INSTANCE_NAME=pdb7)(SERVER=DEDICATED)))'
Since there is an old IP in the configuration we must change it
DGMGRL> edit database pdb7 set property StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.15.2.112)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=pdb7_DGMGRL)(INSTANCE_NAME=pdb7)(SERVER=DEDICATED)))';

Property "staticconnectidentifier" updated
I recommend to do the same change with hostname instead of the IP address
DGMGRL> edit database pdb7 set property StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=e15lfs2)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=pdb7_DGMGRL)(INSTANCE_NAME=pdb7)(SERVER=DEDICATED)))';

Property "staticconnectidentifier" updated
Show detailed information of the Standby
DGMGRL> show database sdb7 StaticConnectIdentifier

  StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=e15rfs2.axxana.local)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=sdb7_DGMGRL)(INSTANCE_NAME=sdb7)(SERVER=DEDICATED)))'
This configuration has a hostname and not an IP address, so we don't need to change anything in the Standby.
DGMGRL> show far_sync fdb7 StaticConnectIdentifier

  StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.15.1.63)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=fdb7_DGMGRL)(INSTANCE_NAME=fdb7)(SERVER=DEDICATED)))';
We don't need to change the Far Sync configuration because it is not being used.
DGMGRL> edit far_sync fdb7 set property StaticConnectIdentifier = '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=10.15.2.111)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=fdb7_DGMGRL)(INSTANCE_NAME=fdb7)(SERVER=DEDICATED)))';

Error: ORA-16831: operation not allowed on this member

Failed.
The reason:

  • If you use a TNS alias for the StaticConnectIdentifier, you can change the alias definition like you may already be doing for DGConnectIdentifier.


  • The StaticConnectIdentifier is only used by the broker to remotely start an instance. This is required for switchover, convert, and reinstatement of the old primary to a physical standby after a failover. The StaticConnectIdentifier property is not used for a Far Sync instance as there's never any need for the broker to restart it.


Comments

  1. A comment I got from Oracle's Software Development Director:

    "
    - If you use a TNS alias for the StaticConnectIdentifier, you can change the alias definition like you may already be doing for DGConnectIdentifier.
    - The StaticConnectIdentifier is only used by the broker to remotely start an instance. This is required for switchover, convert, and reinstatement of the old primary to a physical standby after a failover. The StaticConnectIdentifier property is not used for a Far Sync Instance as there's never any need for the broker to restart it.
    "

    ReplyDelete

Post a Comment

Popular posts from this blog

Install Oracle Internet Directory (OID) in Standalone mode

Fixing & Registering ORACLE_HOMES in Central Inventory