For more information regarding the security incident at F5, the actions we are taking to address it, and our ongoing efforts to protect our customers, click here.

Forum Discussion

haripriya_20011's avatar
haripriya_20011
Icon for Nimbostratus rankNimbostratus
Aug 14, 2015

static sticky entry using source address persistence

All the traffic from a particular source IP ,always need to go a specific backend server.How can i acheive that on F5.

 

On cisco we have can configure using static sticky entry .Need some assistance as we are in process of migration of all our application from cisco to F5.

 

cisco config.

 

sticky ip-netmask 255.255.255.255 address source vip_STICKY serverfarm pool timeout 1 replicate sticky 8 static client source 192.168.10.5 rserver app1

 

how to achive this in f5

 

7 Replies

  • You may simply use source_addr as Default Persistence Profile in your virtual-server's config.

     

    If you want to replicate the persistence to HA peer you'll have to enable Mirror Persistence in the source_addr persistence profile.

     

  • 1 particular client IP need to make a connection to only 1 backend server. we want to make sure the that client :192.168.10.5 has a sticky entry stick to only app1 memeber

     

    this vip contains 12 members in th pool

     

  • Then you'll have to use an iRule similar to this:

    when CLIENT_ACCEPTED {
      if { [IP::client_addr] == "192.168.10.5" } {
        pool my_Pool member 10.1.2.200 80
      }
    }
    
  • Christophe thanks for your response ,so how i can verify that all the connection from the client 192.168.10.5 are always going to the pool member 10.1.2.200

     

    please let me know

     

  • you can verify with tmsh command:

    show sys connection cs-client-addr 192.168.10.5 cs-server-addr vs_server_ip
    
  • Thanks all for your response ,I have one more question .if I need have 2 client IPs need to always connects to 2 different servers .Then how should my irule look like . DO i need 2 irules for it .

     

    client :192.168.10.5 -----> server 10.1.2.200 client : 192.168.11.6 ------> server 10.1.2.205