Forum Discussion
zak_thompson_86
Nimbostratus
May 12, 2007404 reselect help
so i'm trying to create somthing that will try every pool member for a response and once it goes through every active member and they are all 404's to default to a pool that will always have the content. this is needed to help serve content while the servers are syncing with each other.
when CLIENT_ACCEPTED {
set retries 0
}
when HTTP_REQUEST {
set request [HTTP::request]
}
when LB_SELECTED {
if {$retries >= [active_members ddf-big-media01] } {
LB::reselect pool ddf-backend
log local0. "RETRY!"
}
}
when HTTP_RESPONSE {
if { [LB::server pool] equals "ddf-big-media01" } {
if { [LB::server pool] != "ddf-backend" } {
if { [HTTP::status] eq "404" } {
incr retries
log local0. "REtrying pool"
HTTP::retry $request
}
}
}
}I see in examples people say to use the LB::reselect syntax inside http_response however.. the appliance screams at me everytime i try and wont let me do it. there a way around this??
2 Replies
- Colin_Walker_12Historic F5 AccountThere was some confusion initially around the LB::reselect command and where it was applicable. It looks like you're implementing it in the intended fashion, as it's not usable under the response event.
Is your rule working?
Colin - zak_thompson_86
Nimbostratus
no its not working, it would flip to the other pool right away it never tried the other nodes.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
