Forum Discussion
WUM_113639
Nimbostratus
Oct 10, 2013http request redirection/rewrite
Hello,
I am having problem in simple redirection....
I want to redirect clients hitting the VIP ip address (http://10.1.1.1) to (http://web-server/mypage)
I have written following irule but it doesn't seem to be working....when HTTP::request {
if { [HTTP::host] equals "http://10.1.1.1" } {
HTTP::redirect "http://web-server/mypage"
}
}I would appreciate answers...
5 Replies
- Cory_50405
Noctilucent
Try this:
when HTTP_REQUEST { if { [HTTP::host] equals "10.1.1.1" } { HTTP::redirect "http://web-server/mypage" } } - WUM_113639
Nimbostratus
Thanks for your answer Cory...
I forgot to mention that...I had also tried that as well but it had not worked....
I will again give it a try...
- Cory_50405
Noctilucent
The trigger wasn't properly formatted in what you posted above. Also, HTTP::host will only return the host IP address without any http:// You tried it before exactly as I posted above and it did not work?
- WUM_113639
Nimbostratus
Thanks cory ... it worked.
- Cory_50405
Noctilucent
Good to hear.
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