Forum Discussion

rsbs01's avatar
rsbs01
Icon for Nimbostratus rankNimbostratus
May 28, 2018

Cookie based redirection to the specific pool member.

Hello everybody.

 

I have one issue that I would like to ask about. I've been searching DevCentral but I did not really find a solution to my problem. The scenario is following: VIP listening on: 10.20.30.40 pool with 4 members: PM_01 (10.20.30.50), PM_02 (10.20.30.51), PM_03 (10.20.30.52), PM_04 (10.20.30.53) persistence: source_addr

 

What I need to do is following. I need to have cookie persistence on the pool members PM_01 and PM_02, PM_03 and PM_04 should remain with source_addr persistence. I know, that configuring persistence at the VIP-level means, that this persistence will be used on the whole pool. So the only option is to use iRule to tell the VIP, that it should use cookie persistence for PM_01 and PM_02, source_addr persistence for PM_03 and PM_04. I found some examples, but those used redirection to the different pools, while I have to keep this one pool only and redirect to the specific members of the pool.

 

Can anyone help, please?

 

1 Reply

  • Create two pools

     

    Pool1 with two members PM_01 and PM_02 Pool2 with two members PM_03 and PM_04

     

    Apply below irule and try the connectivity.

     

    when HTTP_REQUEST { if{([HTTP::cookie exists ""]) and ([HTTP::cookie value "