Forum Discussion
junglefox_13333
Nimbostratus
Sep 10, 2013Plz help! Why is my irules not working
Hi every f5ers!
My company owns several IP and I want to allocate one(ex 6.6.6.6) for visting a website(with a static ip,ex 8.8.8.8) instead of using selfip of our f5 ltm.I wrote irules as below,as...
StephanManthey
Nacreous
Sep 16, 2013Please change your iRule as follows:
[IP::addr [LB::server addr] equals 202.215.132.119]
into:
[IP::addr [IP::local_addr] equals 202.215.132.119]
The function [IP::local_addr] in the clientside context will evaluate the destination IP:
when CLIENT_ACCEPTED {
log local0. "[IP::client_addr]:[TCP::client_port]: Connected=[IP::local_addr]:[TCP::client_port] [virtual name]"
if {[IP::addr [IP::local_addr] equals 202.215.132.119] } {
snat 124.232.132.94
log local0. "[IP::client_addr]:[TCP::client_port], matched=202.215.132.119"
} else {
snat automap
log local0. "[IP::client_addr]:[TCP::client_port], not matched=202.215.132.119"
}
}
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