Alternate Servers
- Last Updated: March 29, 2022
- 1 minute read
- DataDirect Connectors
- ODBC
- IBM Db2 8.0
- Documentation
Alternate Servers
Attribute
AlternateServers (ASRV)
Purpose
A list of alternate database servers to which the driver tries to connect if the primary database server is unavailable. Specifying a value for this option enables connection failover for the driver. The value you specify must be in the form of a string that defines the physical location of each alternate server. All of the other required connection information for each alternate server is the same as what is defined for the primary server connection.
Valid Values
(IPAddress=ipvalue:TcpPort=portvalue:{Database
| Location}=
databasevalue
[,
. . .])
You must specify the IP address, port number, and database name (Db2 for Linux/UNIX/Windows, Db2 Hosted, and Db2 Warehouse on Cloud) or location (Db2 for z/OS and Db2 for i) of each alternate server.
Example
The following Alternate Servers values define two alternate database servers for connection failover:
AlternateServers=(IpAddress=123.456.78.90:TcpPort=5177:Database=Db2DAT, IpAddress=223.456.78.90:TcpPort=5178:Database=Db2DAT3)
or
AlternateServers=(IpAddress=123.456.78.90:
TcpPort=5177:Location=Db2DAT, IpAddress=223.456.78.90:TcpPort=5178:
Location=Db2DAT3)
Notes
- An alternate server address in IPv6 format must be enclosed in double quotation marks.
Default
None