Forum Discussion
srantos_87030
Jul 25, 2012Nimbostratus
iRule to bypass default pool
Hello,
I am using a virtual server to load-balance HTTP traffic from customers to a pool of traffic servers. I need an iRule to bypass this pool and send the HTTP requests to an Internet pro...
hooleylist
Jul 25, 2012Cirrostratus
This is the default connection based load balancing behavior. To have LTM load balance per HTTP request you can either add a OneConnect profile to the VS or specify a pool in every case when you're specifying a pool for any case. Here's an example of the latter:
when CLIENT_ACCEPTED {
Save the name of the VS default pool before it is changed in this iRule
set default_pool [LB::server pool]
}
when HTTP_REQUEST {
if {[string tolower [HTTP::host]] contains "facebook"}{
log local0. "Using isa pool for HTTP Host: [HTTP::host]"
pool isa_pool
snat automap
} else {
log local0. "Using default pool $default_pool for HTTP Host: [HTTP::host]"
pool $default_pool
snat none
}
}
Aaron
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