Forum Discussion
Roman_80473
Jan 16, 2012Nimbostratus
Get addresses of unavailable pool members?
Hi folks,
Is there a way to get a list (ip:port) of all marked down members in the pool using an iRule? After detecting all members are down in HTTP_REQUEST:
if { [active_members [LB::server pool]] == 0 && [LB::server addr] == "" } {
...
I need to list all offline members in the pool!
I know it's possible with an iControl, but I wasn't sure about iRule.
Any help is appreciated.
Thank you, Roman
8 Replies
Sort By
- Hi Roman,
- Hi Aaron,
- If you can use that logic on a non-client facing virtual server it should be fine in terms of LTM resources. Else, I'd try building an iControl app to get the downed member info. Or maybe you can use SNMP traps from LTM to notify the external app that a pool member has been marked down.
- I see what you're saying, maybe I need to reconsider ... I was thinking to send HTTP sideband request with a list of offline members to that external app (it forks another thread and returns instantly back) as in the example:
- I'd try to avoid tying the pool member restart logic to the load balancing of client traffic. Doing this on the client virtual server would add unnecessary load to LTM. Ideally, you could either poll LTM from a remote host to look for newly downed pool members or set up a trap so LTM can notify the external app when a pool member gets marked down.
- Hi Aaron,
- You could use the log command to write something informative to the local filesystem when a pool member is down. Default logging will already tell you whether a monitor failed. If you're using 'Fallback on Error Codes' on the HTTP profile, I don't think that would be logged as we don't log anything by default for individual request/LB failures. In v11, you can use [event info] in LB_FAILED to check why the event was triggered. In v10, I don't think it's possible to determine why LB_FAILED was triggered. However, I'm not sure you'd want to restart services if an individual connection attempt or HTTP request failed. So maybe it only makes sense to trigger the service restart if the pool member is actually marked down.
- You're right, it prob makes more sense to mark down pool member inside an iRule, and then act on that via iControl.
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