Forum Discussion

Héctor's avatar
Héctor
Icon for Altostratus rankAltostratus
Oct 11, 2019

irules or monitors

Hi All,

 

we've got a Virtual Server (tcp port 16000), a pool with 2 members, same tcp port. The applicative will be running only in one of the members at a time. In case of applicative error, the failover method is through a script that connects via virtual server an starts the services (tcp port) in the other member. Because of that, we need the members to be up, although any of them have the service started (only tcp monitor is not viable because passive member need to be accesed in case of app error, in order the script starts the services).

 

Any suggestion?

 

Thanks in advance.

 

Kind regards

2 Replies

  • Hi

     

    Are you able to use a monitor that checks a Receive String to determine availability?

     

    If so, you could set up two pools. The first pool would be for your application traffic (and default pool for the VIP) and contain the monitor that checks for the service being up.

     

    Then you can create a second identical pool, with a seperate monitor that has all of the same settings EXCEPT that Reverse is set to Yes. The logic being here that if the Receive String is found, the server gets marked as being down. If the string is not found then the server is marked as being Up.

     

    Then, write some code similar to below that looks for the request from your script connection and send it to the 2nd pool.

     

    when CLIENT_ACCEPTED {

     if { [IP::addr [IP::client_addr] equals 10.10.10.10] } {

       pool second_pool

     }

    }

  • Rocío's avatar
    Rocío
    Icon for Nimbostratus rankNimbostratus

    Couldn't an iRule be made that detects whether port 16000 is active, and depending on that you send it to one pool or another?if that's what the structure of the iRule might be?