Forum Discussion
Mahantesh_Bisur
Nimbostratus
Aug 05, 2015SNAT iRule based on client IP address
Hi All,
I am looking for an Irule on a virtual server to use a different snatpool based on the actual client ip address and this has to scale up to multiple different clients(around 50 to 100) ...
Aug 06, 2015
Hi!
I think I understand now.
If the ration between customer IP and NAT pool is 1:1 I'd use something like this:
when CLIENT_ACCEPTED {
if { [IP::addr [IP::client_addr] equals 10.0.0.1] {
snatpool SNATPOOLX
} elseif { [IP::addr [IP::client_addr] equals 10.0.0.,2] } }{
snatpool SNATPOOLY
} elseif { [IP::addr [IP::client_addr] equals 10.0.0.3] } }{
snatpool SNATPOOLZ
}
}
If you expect the ration to be more than one and changing I'd use the first rule I wrote.
/Patrik
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects