Forum Discussion
dennypayne
Feb 02, 2009Employee
A generic rule like this would work fine:
when HTTP_REQUEST {
HTTP::redirect "http://www.oursite.com"
}
but it would have to be manually added to the vip whenever you took the primary nodes out of service.
So, something a little more elegant might be to use a 2 statements like this (with an AND):
if { [LB::status pool member ] eq "down" }
where you hardcode the pool name and the primary nodes' IP's and ports into the and sections. That's of course assuming that those nodes don't change. Then when the iRule detects that you've disabled the primary nodes, it should begin doing the redirect.
I'm having a hard time thinking of anything more portable than that...
Denny