Forum Discussion
swo0sh_gt_13163
Altostratus
Sep 05, 2013HTTP Redirection based on pool members availability.
Hello Folks,
Can you please share an iRule sample code which should redirect HTTP traffic to my DR site if pool members at Primary sites are down.
Regards,
Darshan
Kevin_Stewart
Employee
Sep 05, 2013Well, one of the simplest things you could do might look like this:
when HTTP_REQUEST {
if { [active_members http_pool] < 1 } {
HTTP::redirect "http://dr-site.example.com"
}
}
where "http_pool" is the name of the pool assigned to the VIP (along with this iRule). I'd also add that this is a good case for global server load balancing (GSLB) where users are redirected via DNS to different data centers based on health and availability.
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