RichKL_77280
Aug 18, 2008Nimbostratus
Pool member: Force offline
I'm using LocalLBPoolMember.get_session_status to tell what a particular pool member's status is.
The three statuses I'm trying to be able to query and modify through this code, as taken from the web interface:
Enabled (All traffic allowed)
Disabled (Only persistent or active connections allowed)
Forced Offline (Only active connections allowed)
I don't believe get_session_enabled_state is the function I want to use to query those statuses, because it only has two possible values:
STATE_DISABLED
STATE_ENABLED
I think get_session_status is the right one, but am confused by it's four possible values:
SESSION_STATUS_ENABLED
SESSION_STATUS_DISABLED
SESSION_STATUS_FORCED_DISABLED
SESSION_STATUS_ADDRESS_DISABLED
I don't know what address_disabled is, but the rest of those statuses look like they correspond to the web interface's options for a pool member's status.
So, here's the real question: How come there's no LocalLBPoolMember.set_session_status? How does the web interface change those values? How do I? I've seen the previous thread about gracefully disabling a node, but implementing a timed poll and then doing a set_monitor_state to finally disable the node does not seem like what the web interface is doing. Can you help me figure what it is I need to call?