Forum Discussion
iRULE to Select Node based on different Pool
I'm assuming that you want to use Webnode1 and Appnode1. If Webnode1 is down you want to use Webnode2 and Appnode2, except if Appnode2 is down. In that case you still want to use Appnode1.
To accomplish this (and to prevent hard-coding more node IP-addresses than necessary) I would create a fall-back pool that is the inverse of APP-Pool (i.e. switch the priority groups). In the iRule I used the name APP-Pool-Fallback for this pool.
Here's the rule you would then apply to the VIP for APP:
when HTTP_REQUEST {
if { [LB::status pool WEB-Pool member 10.1.2.101 80] eq "down" } {
pool APP-Pool-Fallback
}
}
Note: replace "10.1.2.101" with the IP-address of Webnode1.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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