Forum Discussion
John_Watilo_483
Nimbostratus
Aug 14, 2013Weighted Least Connections: How to add a pool member via iControl interface
We are using the iControl interface to manipulate pools/members in devices running version 10.2.3. Whenever we have configured a pool with a Load Balancing method of "Weighted Least Connections", an...
philh_127905
Nimbostratus
Aug 15, 2013You're right, it's a trap !
I don't know if this would work in your solution, but one workaround might be to use the "weighted-least-connections-node" load balancing mode. Then you could create the node with a connection limit and add it to a pool:
!/usr/bin/env ruby
require "rubygems"
require "f5-icontrol"
@ic = F5::IControl.new("10.2.2.29","user","pass", ["LocalLB.Pool","LocalLB.NodeAddress"]).get_interfaces
ipport_def = {"address" => "10.10.10.10", "port" => 80}
connection_limit = 5
pool_name = "test_ic_pool"
Create the node
@ic["LocalLB.NodeAddress"].create([ipport_def['address']],[connection_limit])
Add it as a pool member
@ic["LocalLB.Pool"].add_member([pool_name],[[ipport_def]])
I guess there is the option of writing a weighted least connections (memeber) lb mode in an iRule and disregarding the mode of the actual pool. That way you could dynamically add pool members and not have to worry about this trap.
Hope that helps
Phil
John_Watilo_483
Nimbostratus
Aug 15, 2013Thanks, Phil. I appreciate the quick reply. I'll look into this...
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