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...
crosson_16669
Jan 03, 2013Nimbostratus
I have tried all the variations you gave above plus some alterations of it. I get the following.
XSD::ValueSpaceError: {urn:iControl}Common.EnabledState: cannot accept ''
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/wsdl/xmlSchema/simpleType.rb:66:in `check_restriction'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/wsdl/xmlSchema/simpleType.rb:23:in `check_lexical_format'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:125:in `simpleobj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:118:in `obj2typesoap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:44:in `obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:127:in `_obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:210:in `elements2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:206:in `each'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:206:in `elements2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:167:in `struct2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:134:in `complexobj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:120:in `obj2typesoap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:44:in `obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:127:in `_obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:179:in `array2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:178:in `each'
... 14 levels...
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:206:in `elements2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:167:in `struct2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:134:in `complexobj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:120:in `obj2typesoap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/wsdlencodedregistry.rb:44:in `obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:127:in `_obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:47:in `obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:360:in `protect_threadvars'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/mapping/mapping.rb:43:in `obj2soap'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/proxy.rb:394:in `request_rpc_enc'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/proxy.rb:376:in `request_rpc'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/proxy.rb:338:in `request_body'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/proxy.rb:123:in `call'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/driver.rb:178:in `call'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/soap/rpc/driver.rb:232:in `set_monitor_state'
from (irb):135>>
I know that the argument expects two arguments since if I pass 1 or 3 it fails asking for two. So I tried the following examples
member = {:port=>0, :address=>"172.16.20.65"}
monitor_state = "STATE_DISABLE"
@ltm["LocalLB.PoolMember"].set_monitor_state(@poolname, [member, monitor_state])
@ltm["LocalLB.PoolMember"].set_monitor_state([@poolname], [member, monitor_state])
@ltm["LocalLB.PoolMember"].set_monitor_state(@poolname, [[member], [monitor_state]])
I get the same error on all of them
The API asks for a struct so I took it to the next extreme via the following.
Struct.new("Member", :address, :port)
Struct.new("Member_status", :member, :status)
m = Struct::Member.new("172.16.20.65", 0)
ms = Struct::Member_status.new(m, 0)
@ltm["LocalLB.PoolMember"].set_monitor_state(@poolname, ms)
API Says it expects a MemberMonitorState which is a struct of IpPortDefinition and EnabledState. IpPortDefinition is a struct of a string, Address, and long, port. The EnabledState looks like simply a 0 or 1.
https://devcentral.f5.com/wiki/iControl.LocalLB__PoolMember__set_monitor_state.ashx
Anyhow I get the same errors
XSD::ValueSpaceError: {urn:iControl}Common.EnabledState: cannot accept ''
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