Forum Discussion
meena_60183
Nimbostratus
Jun 28, 2010Is this correct?
I am trying to write an irule where I perform snat based on the LB_SELECTED server address and this is what I have
when LB_SELECTED {
Check the CAS server and do SNAT
log...
meena_60183
Nimbostratus
Jun 28, 2010Thanks Aaron.
Now I do not get the error on the log but I do have one question. I need to use the cas_selected variable in another irule which gets hit when the traffic comes out of the cas servers on the trusted side which I do have a wildcard forwarding VS that is enabled on the trusted side (vlan) of the CAS server. I need to make sure that when a response comes back from other servers, I need to force the traffic through the same cas server that was selected on the untrusted side. When I use a local variable, I get the following
Jun 28 16:47:25 tmm1 tmm1[2268]: 01220001:3: TCL error: snat_cas_untrusted_addr - can't read "cas_selected": no such variable while executing "log local0. "selected CAS-second is $cas_selected""
for this irule
when LB_SELECTED {
log local0. "selected CAS-second is $cas_selected"
if { $cas_selected equals "10.60.252.6" } {
snat 10.60.253.254
forward
} elseif { $cas_selected equals "10.60.252.7" } {
snat 10.60.253.253
forward
} elseif { $cas_selected equals "10.60.252.8" } {
snat 10.60.253.252
forward
}
}
I tried to make it a global variable and that gives me the same error as well.
Meena
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