Forum Discussion

sujohnm_88706's avatar
sujohnm_88706
Icon for Nimbostratus rankNimbostratus
Sep 25, 2018

irule for sorry pool and removing persistence on sorry pool

Hello there, I have a VIP with source IP persistence. I would like to create an irule for a sorry pool on this VIP and remove the persistence on the sorry pool as clients seem to persist to it even after the main web servers have been restored. I have created the below. Please let me know if this will work or if there's an easier way to do this. BigIP Version 12.1.3.4 VE

 

when HTTP_REQUEST { if {[active_members [LB::APP_VIP_HTTPS]] == 0}{ persist none pool sorry_APP_HTTPS_pool } else { pool APP_HTTPS_pool

 

2 Replies

  • Seem to loose the formatting. Hope this helps explain my irule

     

    when HTTP_REQUEST {

     

    if {[active_members [LB::APP_VIP_HTTPS]] == 0}{

     

    persist none

     

    pool sorry_APP_HTTPS_pool

     

    } else { pool APP_HTTPS_pool

     

  • If you did not have persistence you could use priority group for that:

     

    https://support.f5.com/csp/article/K7065

     

    With persistence, the only option I see is iRule (or LTM policy):

     

    when HTTP_REQUEST {
       if { [active_members APP_HTTPS_pool] < 1 } {
       persist none
       pool sorry_APP_HTTPS_pool 
    }

    When posting code, use the fourth button on the top to format for code.