Forum Discussion
andrew_C1
Feb 11, 2016Nimbostratus
Best way to set a pool member as Disable from Irule
Hi all,
I have a requirement that needs pool members to be disabled when a certain number of concurrent sessions has been reached to stop new sessions going to the member ( memory locking errors...
andrew_C1
Feb 12, 2016Nimbostratus
based off this post https://devcentral.f5.com/questions/how-to-run-a-bash-script-in-irule-with-a-parameter-to-that-bash-script-
i have used a sideband connection with a PUT to icontrol to set the member as user-disabled. The only issue is that i have to use a data group to translate from member ip:port ( what i rules use) to member name (what i control).
Anyone know a better way then a data group to do this?
the magic line for the put looks like:
`set req "PUT /mgmt/tm/ltm/pool/~[lindex $test end-1]~[lindex $test end]/members/~[lindex $test end-1]~$member:$port HTTP/1.1\r\nHost: localhost\r\nAuthorization: Basic BASE64GOESHERE\r\nContent-Type:application/json\r\nContent-Length: 27\r\n\r\n{\"session\":\"user-disabled\"}"`
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