Forum Discussion
crosson_16669
Dec 19, 2012Nimbostratus
Confusion on changing a pool member state
I can display states, nodes, and virtual servers just fine. Attached screenshot is my lazy attempt at diving into only the surface of the iControl api. For the most part I found the API docume...
Dec 19, 2012
I think you are munging two data types together in your member_state hash. Instead, try something like this:
member = {:address => "172.16.20.65", :port => 0}
monitor_state = "STATE_DISABLED"
your next issue is likely due to the fact that the set_monitor_state method wants you to pass in an array of pool names and an array of arrays for the member
set_member_monitor_state(
in String [] pool_names,
in Common__AddressPort [] [] members,
in EnabledState [] [] monitor_states
);
that's what the "[]" and "[] []" mean in the method definition.
so you would need something like this (if you just wanted to mess around with a single pool and single pool member in the pool)
@ltm["LocalLB.PoolMember"].set_monitor_state(["tmp_test_pool"],[ member],[[monitor_state]])
also, if you are using v11.x you should be doing all this in the LocalLB::Pool with set_member_monitor_state
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