Verifying the active-passive configuration

Perform the following tests to make sure you have correctly installed and configured the Adaptive Server for active-passive high availability on Sun Cluster 3.0.

  1. Bring the resource group online on its primary node and enable all resources and their fault monitors in the resource group.

    For example:

    scswitch -Z -g rg_MONEY
    
  2. Make sure clients such as isql connect to Adaptive Server using the logical host. To verify client connection failover, connect to Adaptive Server. Use the isql to establish the HA connection (modify the interfaces file and self-reference hafailover entry, if necessary).

  3. isql -Usa -Ppassword -SMONEY -Q
    1> select @@servername
    2> go
    
    ------------------------------
    MONEY
    
    (1 row affected)
    
  4. Simulate failover, either by:

    Shutting down the server

    isql -Usa -Ppassword -SMONEY
    1> shutdown with nowait
    2> go
    

    Or by relocating the Adaptive Server resource group to the secondary node:

    scswitch -z -h node2 -g rg_MONEY
    
  5. Check connection failover by issuing a command in the isql session started in step 2.

    Enter:

    1> select @@servername
    2> go
    
    CT-LIBRARY error:
             ct_results(): user api layer: internal Client Library error:
    HAFAILOVER:Trying to connect to MONEY server.
    1> select @@servername
    2> go
    ------------------------------
    MONEY
    
    (1 row affected)
    
  6. Simulate failback by relocating the resource group back to the primary node.

    scswitch -z -h node1 -g rg_MONEY
    
  7. Check connection failover by issuing a command in the isql session started in step 2.

    Enter:

    1> select @@servername
    2> go
    
    CT-LIBRARY error:
             ct_results(): user api layer: internal Client Library error:
    HAFAILOVER:Trying to connect to MONEY server.
    1> select @@servername
    2> go
    ------------------------------
    MONEY
    
    (1 row affected)