Forum Discussion
Solution for persistence
Currently I have 4 source client (S1, S2, ...S4) and 1 VIP with 4 pool members (lets say D1,D2,..D4). Those pool members is a TCP based server.
Before I go to the problem, I explain the work flow first:
1. F5 let say will give the pool connection randomly when S1 request to VIP. Let say , S1 will get D3.
2. After some moments, that S1 needs to clear/delete/remove the session which is connected (This is one of the procedure that must be followed from my customer)
3. After that, S1 will again get random pool member... let say D1.
Those are the basic work flow that F5 give. But, my customer doesn't want that way. Whenever S1 server session is removed/delete , it will still get the same Pool Members D3 (exactly before the session is removed).
My customer questions are:
1. Is there any solution for the persistence above? I have tried Source Persistence, and Destination Persistence. But still not resolve his issues.
2. He ask me about "One to one mapping persistence". Is there any solution regarding that persistence? Maybe, my friends here can share me a iRule regarding that persistence?
Thanks
Hartono
- JRahmAdminTo clarify, you want S(x) to always go to D(x) unless it's down? Or do you want S1->D1, S2->D2, S3->D3, and S4->D4? Please advise.
- Hartono_Tjung_1NimbostratusPosted By Jason Rahm on 04/25/2011 03:42 PM
- Steffen_Beach_8NimbostratusAre there really only 4 S, and 4 D systems, or could there be 200 S and 10 D for example?
- Hartono_Tjung_1NimbostratusPosted By Steffen Beach on 04/26/2011 07:39 AM
- JRahmAdminCreate four pools, designating one of your servers as priority in each, cascading down respectively:
pool1 pool2 pool3 pool4
1.1.1.1:80 pri 40 1.1.1.2:80 pri 40 1.1.1.3:80 pri 40 1.1.1.4:80 pri 40
1.1.1.2:80 pri 30 1.1.1.3:80 pri 30 1.1.1.4:80 pri 30 1.1.1.1:80 pri 30
1.1.1.3:80 pri 20 1.1.1.4:80 pri 20 1.1.1.1:80 pri 20 1.1.1.2:80 pri 20
1.1.1.4:80 pri 10 1.1.1.1:80 pri 10 1.1.1.2:80 pri 10 1.1.1.3:80 pri 10
when CLIENT_ACCEPTED { switch [IP::remote_addr] { "src_ip_S1" { pool pool1 } "src_ip_S2" { pool pool2 } "src_ip_S3" { pool pool3 } "src_ip_S4" { pool pool4 } default { pool default } } }
- Hartono_Tjung_1NimbostratusPosted By Jason Rahm on 04/27/2011 12:20 PM Create four pools, designating one of your servers as priority in each, cascading down respectively:
pool1 pool2 pool3 pool4
1.1.1.1:80 pri 40 1.1.1.2:80 pri 40 1.1.1.3:80 pri 40 1.1.1.4:80 pri 40
1.1.1.2:80 pri 30 1.1.1.3:80 pri 30 1.1.1.4:80 pri 30 1.1.1.1:80 pri 30
1.1.1.3:80 pri 20 1.1.1.4:80 pri 20 1.1.1.1:80 pri 20 1.1.1.2:80 pri 20
1.1.1.4:80 pri 10 1.1.1.1:80 pri 10 1.1.1.2:80 pri 10 1.1.1.3:80 pri 10
when CLIENT_ACCEPTED { switch [IP::remote_addr] { "src_ip_S1" { pool pool1 } "src_ip_S2" { pool pool2 } "src_ip_S3" { pool pool3 } "src_ip_S4" { pool pool4 } default { pool default } } }
- JRahmAdminOne virtual server with this iRule attached. No pool definition is required on the virtual. The default clause in the switch statement is where you'd specify the default pool if you have one, which could be p1->p4 or a separate one entirely. It is a best practice to configure a default pool on the virtual server, and it can be anything. It will be overrided by the iRule, but is a nice safety net.
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com