Forum Discussion
hooleylist
Jul 29, 2009Cirrostratus
Hi Dave,
The active_members -list command (Click here) returns a TCL list of the IP and port of the active pool members of a given pool. You'd need to loop through each list element and compare the client IP to the IP address from the element. I think it's a novel concept, but not very efficient to implement compared with creating two separate VIPs for the two types of traffic handling.
Now, if there was an active_nodes -list command (Click here), you could do something like:
when CLIENT_ACCEPTED {
if {[matchclass [IP::client_addr] equals [active_nodes -list [LB::server pool]]]}{
log local0. "[IP::client_addr] a member of pool [LB::server pool]"
snat automap
}
}
Oddly enough, in 9.4.7, [active_nodes -list $pool] doesn't trigger a syntax or a runtime error--it just returns the same thing that active_members -list does?!
[active_nodes [LB::server pool]]: 1
[active_nodes -list [LB::server pool]]: {10.11.2.201 82}
[active_members -list [LB::server pool]]: {10.11.2.201 82}
Aaron