Forum Discussion

Narendra_26827's avatar
Icon for Nimbostratus rankNimbostratus
Jul 06, 2011

Creating iRule to disable pool if any subsystem pool member fails




We have a java application that actually runs on linux machine. It has three subsystem processes running on different ports 8086, 8087 and 8088 on single ip address.



We have created a virtual server pointed to port 80 internally pointing to nginx on that particular machine, where we have these three sub java processes.



For these three subsystems we have created separate pools and a separate pool for nginx which is default pool in the virtual server.



We have created a irule that will redirect the requests accordingly to each subsystem and applied to this virtual server like



if /api/gateway* url it should go to gateway pool running on on 8087



if /api/channel* url it should go to channel pool running on 8088



if /api/space* url it should go to space pool running on 8089



Now we want to create a irule which will actually check these three subsystems on that single node and if each of those are not running or getting failed then the request should not go to other two subsystems.



Can anybody help or provide any ideas on creating that irule?





4 Replies

  • Hi Narendra,



    You can configure a separate monitor with the destination port hard coded for the gateway, channel and space services. Then assign all three monitors to each pool with the availability set to 3. If any of the monitors fail, all three services will be marked down.



  • Thanks for the quick reply!



    I have one doubt here, suppose we have multiple nodes to each of those sub system pools like this



  ----> gateway pool




 > channel pool




 > space pool




    Then suppose any member of any of the subsystem pool has failed suppose has failed then request will not go to and node


    but will the request go to and nodes? According to your concept above?



    Sorry if i have asked anything wrong.



  • The idea behind the hard coded destination monitor is that you're saying for each pool member IP, monitor port 8087, 8088 and 8089. If any of the three monitors on that IP fail, then mark down all three ports for that IP. It won't affect other pool member IP's.