Forum Discussion
Snat iRule forLC
I have a link controller setup and i want the server1 and server2 to be translated to separate snat pools and go out via different gateway pool and the rest of the traffic should go out via default snatpool and gateway pool. So i have written the below iRule can some one comment if this is correct or there is some problem in the coding?
when CLIENT_ACCEPTED {
if { [class match [IP::client_addr] equals "Server1"]} {
snatpool snat_proxy1
pool GW_ISP1_Pool
} elseif {[class match [IP::client_addr] equals "Server2"]} {
snatpool snat_proxy2
pool GW_ISP2_Pool
}else {
snatpool Default
pool gateway_pool
}
}
4 Replies
- JRahm
Admin
yep, that looks about right. - hoolio
Cirrostratus
And a dupe of this post: https://devcentral.f5.com/questions/irule-correct-or-not
- Sam01_131907
Nimbostratus
it is not working and i took a tcp dump on the exit interfaces ans all traffic goes to old core router and not new core router. - Techgeeeg
Nimbostratus
Hi Sam what was your senario and what you tested exactly and found not working????
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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