iRule Assistance
Hello, Glorious people of DevCentral,
I am facing an issue with a couple of iRules that are doing the same thing. First off, here is what the iRule looks like:
when HTTP_REQUEST {
if{[HTTP::host] eq "example.home.com" and
[HTTP::path] matches_regex "/home(/.*)\?" or
[HTTP::path] matches_regex "/home/services(/.*)\?" or
[HTTP::path] matches_regex "/index(/.*)\?" or
[HTTP::path] matches_regex "/default(/.*)\?" or
[HTTP::path] matches_regex "/home/services/register(/.*)\?" }
pool myPool
ASM::enable MyPoolASM
}
I have one Virtual Server where I am applying 5 iRules, and all these 5 iRules have the same pattern, but different regex matches and different pools to send traffic to. Now, when I put one iRule (like the one above), it works properly without any issues. However, if I put more than 1 iRule it immediately stops working and I get resets from the F5. All 5 iRules are looking for the same host match (example.home.com) so the first 2 lines of all 5 iRules are same.
Please let me know if I am doing anything wrong in the iRule, or if I can have multiple iRules with the "when HTTP_REQUEST" on a same VS.
Thank You, Mohammad Hamad