Configuring for query port backup

Another use for multiple network interfaces is to provide a backup in case of network failure. If a client is connected to a server via two networks, the client can establish a connection via the second network if the first one goes down.

To configure an instance for query port backup:

  1. Install multiple “master” and “query” lines in a server entry in the interfaces file.

  2. An instance listens for connections at both ports. Clients looking for a host name and a port number for a connection to an instance try the port on each “query” line in order, until they establish a connection.

    The following example shows how to configure a backup network that will be used only if the normal connection fails. The primary network is “corporate network” and backup is “engineering network.”

     # PRODUCTION server with two network listeners
     PRODUCTION<tab>3<tab>3<newline>
     <tab>master tcp ether SERV_CORPNET 4559
     <tab>master tcp ether SERV_ENGNET 5479
     <tab>query tcp ether SERV_CORPNET 4559
     <tab>query tcp ether SERV_ENGNET 5479
    
  3. Configure PC-client interfaces files with the appropriate multiple “query” entries, as described in the Open Client documentation. For client interfaces files in a homogeneous environment, you can copy the entire interfaces file entry for the instance into the client interfaces file.

  4. A connection on the secondary port occurs only if the corporate network is disabled, or if the corporate network interface on the host machine fails or is shut down due to a network-related failure.