Forum Discussion
Justin_Haggerty
Nimbostratus
Dec 21, 2006redirect works on some machines, doesn't on others
I've got the following rule in place:
when HTTP_REQUEST {
if { [HTTP::host] contains "old.com" } {
HTTP::redirect "https://new.com"
}
}
What I'm trying...
Deb_Allen_18
Dec 21, 2006Historic F5 Account
The clients are most likely being redirected, but are unable to follow it completely. You can see if LTM is sending the redirect and whether it is being followed by looking at a packet trace between the client and LTM, and you can see if the browser received & followed it using HTTPWatch (IE) or LiveHeaders (FireFox).
It's worth noting that your target URL is actually not complete, as it doesn't contain a URI (the object being requested), so in following the redirect, the browser and the server both have to do a bit of extra work: The server will send a redirect to the "/" URI (which may or may not be passed along properly through LTM, depending on whether the iRule is applied to a SSL virtual server and whether Rewrite Redirects is enabled), and the browser will have to follow it.
I'd recommend adding a URI to the redirect (if nothing else at least add a trailing "/" to the redirect string) to prevent the above mentioned additional request/response logistics. You might also want to set "Rewrite Redirects" to Matching in the related http profile.
HTH
/deb
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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