Forum Discussion
AndrewM_4835
Nimbostratus
Jun 11, 2008Hash Load Balancing
Dear Forum,
I am looking at trying an iRule to persistently load balance a group of web servers.
I have found an article 'Hash Load Balancing and Persistence on BIG-IP LT...
The_Bhattman
Nimbostratus
Jun 11, 2008Here is a piece of logic that may help.
192.168.1.x represents all the pool members in your test_pool.
.
.
.
set active_members { }
set pool_list { 192.168.1.10 192.168.1.12 192.168.1.13 192.168.1.14 ... etc. }
foreach node_address $pool_list {
if {LB:status pool test_pool member $node_address eq "up" } {
lappend active_members $N
}
}
.
.
.
Least to say I don't like embedding IP addresses into iRule, but I thought it might get you in the right direction and hopefully the iRule pro's in this forum would jump in enhance it or simply figure out a better way. I would also investigate using classes to replace the IP address simply because it's cleaner.
I hope this helps,
CB
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