Loadbalance a URL to 3 URLs
Hi Guys, I have a requirement like when HTTP_REQUEST { if { [HTTP::path] equals "/exampletext" it should loadbalance/roundrobin the redirection to 3 URLs shown below "https://abc1ee.xyz.com/exampletext_1" "https://abc2ee.xyz.com/exampletext_2" "https://abc3ee.xyz.com/exampletext_3" Kindly, help ! TIA725Views0likes6Commentsset TOKEN [getfield [HTTP::uri]
I have two rules that work on there own, not sure how to combine them into one. when HTTP_REQUEST { set HOST [string tolower [HTTP::host]] set TOKEN [getfield [HTTP::uri] "/?r=" 2] HTTP::respond 302 Location "https://www2.google.com/gui/reloan/getstarted?code=$TOKEN" Connection Close } when HTTP_REQUEST { set HOST [string tolower [HTTP::host]] set TOKEN [getfield [HTTP::uri] "/" 2] HTTP::respond 302 Location "https://www1.google.com/ShortUrlLanding/?lmco=$TOKEN" Connection Close }Solved924Views0likes7CommentsiRules fail in v14.1.2.3
I recently upgraded from v12.x to v14.1.2.3 and simple redirect/rewrite iRules seem to fail. At first I removed the iRule, deleted it and just recreated it and this worked for a bit (2nd rule below)! However, it suddenly fails and I cannot tell why this would happen. I have seen a number of similar threads but nothing really answers the issues. I have one irule that contains: when HTTP_REQUEST { switch [string tolower [HTTP::host]] { "support1.xyz.com" { # port 7080 log local0. pool SupportPool } "support2.xyz.com" { # port 7080 log local0. pool SupportPool } } } And another that contains: when HTTP_REQUEST { switch [string tolower [HTTP::host]] { "support2.xyz.com" { if { [HTTP::uri] equals "/" } { HTTP::redirect "/portal/ss/?guest=0"} } "support1.xyz.com" { switch -glob [string tolower [HTTP::uri]] { "/" { HTTP::redirect "/portal/ss" } "/support" { HTTP::redirect "/portal" } "/downloads" { HTTP::redirect "https://ftpdl.xyz.com" } } } } } I've read maybe these are now in conflict with how v14.x looks at iRules? Regardless, this worked flawlessly up until now. I cannot make sense of it as the syntax is correct! Now if any of the URIs are typed it returns a PR_CONNECT_RESET_ERROR error in browser as if the pool or iRule doesn't exist. Is there a new way to express this or new syntax?935Views1like6Comments