Technical Considerations for a Serviceguard Cluster that Spans Multiple IP Subnets, July 2009

20
database and a domain name update for db-srv.hp.com is not needed on a cross-subnet package
failure. Figure 9 shows the sample tnsnames.ora file for this configuration.
Figure 9 – Example tnsnames.ora configuration file for a single instance Oracle database with dedicated protocol address
entries
DB_SRV =
(DESCRIPTION =
(ADDRESS_LIST=
(FAILOVER = on)
(ADDRESS = (PROTOCOL = TCP)(HOST = db-srv1.hp.com)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = db-srv2.hp.com)(PORT = 1521))
)
(CONNECT_DATA=
(SERVICE_NAME = DB_SRV)
(FAILOVER_MODE =
(TYPE=select)
(METHOD=basic)
(RETRIES=180)
(DELAY=1))
)
)
)
The definition in the above tnsnames.ora file instructs the client to connect to a listener on
db-srv1.hp.com first. If a listener is available at that location it will direct connection requests
to the appropriate database instance. In order to quickly traverse the address list in case the IP
address resolving to db-srv1.hp.com is not responding, set the
SQLNET.OUTBOUND_CONNECT_TIMEOUT parameter in the client side SQLNET.ORA file. Oracle
recommends a value of 3 seconds. The entries in bold font in Figure 9 represent defaults that are
automatically set if the tnsnames.ora file contains multiple protocol address entries.
Reconnecting to an available database instance after a connection failure
The “FAILOVER = on” in the tnsnames.ora file enables Transparent Application Failover (TAF)
on the client site which is the default with multiple protocol address lines. TAF allows clients that were
connected to a database while a failure occurs to reconnect to the database when it comes up on an
adoptive node. The following failover parameters are set per default:
(FAILOVER_MODE =
(TYPE=select)
(METHOD=basic)
(RETRIES=180)
(DELAY=1))
If those defaults do not fit, like the database is not expected to be up in 3 minutes (180 retries with 1
second delay between the retries) after a site failure, those parameters can be set explicitly in the
tnsnames.ora file. Figure 9 shows the defaults for those parameters in bold font. Alternatively, TAF
can also be enabled and configured on the server site.
Client access to Oracle RAC instances
The IP addresses which clients use to connect to RAC instances in a SGeRAC cross-subnet cluster are
controlled by Oracle CRS. These are called Oracle Virtual IP (VIP) and each cluster node has its own
VIP. If multiple RAC databases are configured in a single SADTA cluster, all instances running on the
same node use the same VIP. For this reason, it is not recommended, to change the name resolution
of RAC VIP addresses after a cross-subnet failover of a RAC database.