Forum Discussion
Christian_12353
Nimbostratus
May 21, 2014VIP redirect to another VIP
Hello,
I was wondering if there was a way to redirect to another VIP..
so if traffic comes in to one VIP.. an irule or something would send it to another VIP on the same LTM.
Thanks ...
nitass
Employee
May 28, 2014I tried the above irule on http://website.com and https://website.com but it didnt seem like it worked..am I missing something?
doesn't the irule Kevin suggested work?
config
root@(ve11a)(cfg-sync In Sync)(Active)(/Common)(tmos) list ltm virtual bar
ltm virtual bar {
destination 172.28.24.10:80
ip-protocol tcp
mask 255.255.255.255
profiles {
http { }
tcp { }
}
rules {
qux
}
source 0.0.0.0/0
vs-index 35
}
root@(ve11a)(cfg-sync In Sync)(Active)(/Common)(tmos) list ltm rule qux
ltm rule qux {
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] equals "website.com" } {
HTTP::redirect "https://NEWwebsite.com"
}
}
}
test
[root@ve11a:Active:In Sync] config curl -I http://172.28.24.10 -H "Host: website.com"
HTTP/1.0 302 Found
Location: https://NEWwebsite.com
Server: BigIP
Connection: Keep-Alive
Content-Length: 0
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