Forum Discussion
meena_60183
Nimbostratus
Aug 18, 2010persitence entry lookup across two different VS
Hi All,
I have a need to query the persistence table on a VS based on the entry created by another VS and select a node based on the entry.
I created the following irule by looking at other examples in this forum but tcpdump shows the traffic going out from the F5 to the respective client but the client never sees it.
The irule is applied to the second VS and I am trying to look at the perist table based on the client IP. Here is the irule
when CLIENT_ACCEPTED {
if { [matchclass [IP::client_addr] equals $::ie_vlan] & [matchclass [IP::local_addr] equals $::dns_servers]} {
log local0. "client IP is [IP::client_addr]"
log local0. "local address is [IP::local_addr]"
if { [persist lookup simple [IP::client_addr] node] equals "10.44.254.23" }{
pool ie_http_pool member 10.22.255.24 0
log local0. "selected server1"
} elseif { [persist lookup simple [IP::client_addr] node] equals "10.44.254.24" }{
pool ie_http_pool member 10.22.255.23
log local0. "selected server2"
} elseif { [persist lookup simple [IP::client_addr] node] equals "10.44.254.25" }{
pool ie_http_pool member 10.22.255.25 0
log local0. "selected server3"
}
}
}
Is client_accepted a correct event? I am seeing log statements being hit.
Meena
- naladar_65658
Altostratus
This is a tough one because of the way your are doing persistence. Have you read this article and made certain it does not apply to you?when HTTP_REQUEST { Save the value of the UIE persistence record for this client for any pool set value [persist lookup uie "[IP::client_addr] any pool"] }
- meena_60183
Nimbostratus
No, this does not apply since I am using persistence based on the source_addr and not based on a cookie. - L4L7_53191
Nimbostratus
Meena: have you looked at the 'match across virtual servers' entry in the persistence profile options, by chance? Looks like you may be able to avoid an iRule completely. Also have a look at 'match across services' and see if that works for you as well (don't have enough info to tell). - meena_60183
Nimbostratus
Matt,
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