Sams_88783
Jan 25, 2012Nimbostratus
Irule help
We have 2 IIS servers and 2 Apache servers and we are looking for is a way to separate two types of traffic (IIS versus Apache) and send the traffic to different pools.while discarding everything else. It will probably make sense to create two variables; one to list the IIS URLs and the other to list the Apache URLs; as part of this as well.
I have created irule as below:
when HTTP_REQUEST {
if { [HTTP::host] equals "iistest.abc-hhc.com"} {
use pool iis_hosting_pool
}
else if {[HTTP::host] equals "apachetest.abc-hhc.com"} {
use pool apache_hosting_pool
}
else {
discard
}
}
But this is giving syntax error.There will be multiple URLs that will fall in to each category.In version 4.x there is a variable concept, but not finding in 9.x.
Please help urgent.