Forum Discussion
Harry_175563
Nimbostratus
Nov 25, 2014To create an irule to direct traffic irrespective of ports ( all ports)
Hi, can any one help me creating an irule for the following :
source IP: 0.0.0.0/0 destination IP : 0.0.0.0 redirect the traffic of port 80 to one pool and anything else to another pool..
thanks
5 Replies
- Harry_175563
Nimbostratus
to be more descriptive one pool is the bluecoat cacheflow and the other pool is the peerapp device for transparent caching ... the issue is that the traffic gets directed to either of the pool at a given time ... which i want to regulate by creating an irule specifying that anything on port 80 should get redirected to bluecoat cache pool and any other port than port 80 be redirected to the peerapp pool... appreciate help on this - nitass
Employee
you can check destination port using TCP::local_port and send to specific pool using pool command. TCP::local_port https://clouddocs.f5.com/api/irules/TCP__local_port.html pool https://clouddocs.f5.com/api/irules/pool.html by the way, why don't you create 2 virtual servers; one is 0.0.0.0:0/0 and the other one is 0.0.0.0:80/0? so, you do not need the irule. - Harry_175563
Nimbostratus
Hi nitass, "by the way, why don't you create 2 virtual servers; one is 0.0.0.0:0/0 and the other one is 0.0.0.0:80/0? so, you do not need the irule." ....... thats what we did but still dont work ... - nitass
Employee
was there any error in /var/log/ltm? have you tried to capture packet? Below is the iRule:
when CLIENT_ACCEPTED
{
if { [TCP::local_port] eq "80" } {
pool httppool} else {
pool otherPool}
}
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