Forum Discussion
Egbert_Bryant_1
Nimbostratus
Oct 10, 2007irule decision process
I have the following irule that looks at matchclass "Ports" and sends that traffic to the default gateway member 69.74.121.60 and all other traffic to default gateway member 64.94.182.254, however, it seems that the irule is not functioning correctly - when I attempt an SSH/Port 22 connection outbound it sends the traffic to gateway member 69.74.121.60 and not member 64.94.182.254. Please look at the syntax and let me know how to improve it.
when CLIENT_ACCEPTED {
if { [matchclass [IP::client_addr] equals $::nonat_host ]} {
snat none
pool default_gateway_pool member 64.94.182.254
} else {
if { [matchclass [TCP::local_port] equals $::ports] } {
if { [LB::status pool default_gateway_pool member 69.74.121.60 0] equals "up"}{
pool default_gateway_pool member 69.74.121.60
} else {
pool default_gateway_pool member 64.94.182.254
}
}
}
}
class ports {
25
80
443
554
1080
1755
1863
3101
5050
5190
}
- Deb_Allen_18Historic F5 AccountI'd recommend adding some logging to the rule to see what conditions are when the decision points are reached.
- Egbert_Bryant_1
Nimbostratus
It stops processing after the first else statement "Rule tcp_fw_rule_class_rlip CLIENT_ACCEPTED: 1st else statement" this is the message the logging generated. All of the suggestions in your third paragraph are in effect, I will try changing the LB::Status to node. Hopefully this helps, do you have any other suggestions that may help me out.
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