Forum Discussion
cxcal_18687
Jan 26, 2011Nimbostratus
HTTP and URI Redirect
Can someone assist with a iRules with the following requirements:
1) When a client hits "" they should be redirected to "https:///Proxy"
2) If clients hits they should be redire...
Colin_Walker_12
Jan 28, 2011Historic F5 Account
Okay, so if you want to use the HTTP::redirect command, you need an HTTP profile assigned to the VIP. Try using the base HTTP profile and see how that treats you.
Other than that, this rule looks completely correct:
when HTTP_REQUEST {
if { [HTTP::host] equals "uat.ac.com" and [HTTP::uri] equals "/"} {
HTTP::redirect "https://uat.ac.com/Portal"
}
}
If you're getting hung connections when running this iRule, and no errors are showing up in the LTM logs, I'd recommend running something like HTTPWatch or the like to see what's actually happening with the connection. Is it in a redirect loop? Is the back end rejecting the connection? What errors are showing up and from where?
Colin
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