Forum Discussion
Kent_Perrier_50
Nimbostratus
Nov 06, 2007use iControl to set a pool member to Down status?
I am attempting to write perl based iControl script to change pool member status. I have found the the TogglePoolMember script in CodeShare that I am using as a starting point. Unfortunately, I have not been able to see if I can set a pool member's status to DOWN or UP via the iControl API. Can I do this with the API or must the up or down status change be done via ssh and a
b pool members up
or
b pool members down
command?- Don_MacVittie_1Historic F5 AccountYou can, it just takes an extra step or so.
- Kent_Perrier_50
Nimbostratus
It does not. I am using the same code from the TogglePoolMember, but instead of passing a STATE_DISABLED I am passing DOWN and that is not working. Drilling through the API links I end up at http://devcentral.f5.com/wiki/default.aspx/iControl/Common__EnabledState.html and that leads me to believe that the only states you can set via the API is STATE_DISABLED or STATE_ENABLED. - Don_MacVittie_1Historic F5 AccountAhh... You tickled my brain. We had this conversation not long ago so I went and dug it up, sounds like exactly what you're experiencing...
- Kent_Perrier_50
Nimbostratus
So I need to set the MemberMonitorState to DOWN to be the same thing asExtract the 1st list for the single pool passed in. @member_list = @{@member_lists[0]}; build parameters for set_session_enabled_state(); foreach $member_def (@member_list) { $address = $member_def->{"address"}; $port = $member_def->{"port"}; $member = { address => $address, port => $port }; $MemberSessionState = { member => $member, session_state => $state }; push @MemberSessionStateList, $MemberSessionState; }
- Tim_W_72292
Nimbostratus
Aaron, - Deb_Allen_18Historic F5 AccountHi Tim -
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