Filter by:
  • Solution
  • Technology

answers

HELP! using LB_fail

Updated 3/23/2012 • Originally posted on 23-Mar-2012 by Brandon Van 0

So i'm trying to get html to display when active members of the pool are not available. I have tried 4 or 5 different rules and i get the same result which is just the standard IE message.

Here is my latest....

when CLIENT_ACCEPTED {
set my_pool [LB::server pool]
}
when LB_FAILED {
log local0. "[active_members $my_pool]"
if { [active_members $my_pool] < 1 } {
HTTP::respond 200 content {

}
}
}





Please help, i'm kind of a noob to irules.
0
Rate this Question

Answers to this Question

8 Answers:

placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 23-Mar-2012 • Originally posted on 23-Mar-2012 by hoolio 2066
Hi Brandon,

That looks about right. Do you see the LB_FAILED log message?

Can you make a request to the virtual server using curl and check the response as well as the /var/log/ltm output? You can use curl like this to make the request:

curl -v http://1.1.1.1
curl -kv https://1.1.1.1

Aaron
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 26-Mar-2012 • Originally posted on 26-Mar-2012 by Brandon Van 0
I do not see anything in the logs. I was wondering about using the DNS_REQUEST event for the IF statement. for some reason i don't get the desired results with multiple tries on different irules i configured to do the same thing.
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 26-Mar-2012 • Originally posted on 26-Mar-2012 by boneyard 3226
i would start some basic debugging, output something in client_accepted event to check if that part is reached.

then output the selected pool to see if that makes sense.

start simple and then expand.
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 26-Mar-2012 • Originally posted on 26-Mar-2012 by Sashi 0
what do you mean by "standard IE message." are you seeing connection reset error?
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 27-Mar-2012 • Originally posted on 27-Mar-2012 by Brandon Van 0
Boneyard,
I came to that conclusion yesterday and will be testing the irule with some extra log inputs on thursday. Thanks for the push!

Sashi,
"your page cannot be displayed"
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 27-Mar-2012 • Originally posted on 27-Mar-2012 by Brandon Van 0
our web addy is https, i dont know if that is causing a problem or if there is something not enabled. i added additional log inputs and i do not see them in the logs at all. What could be the issue
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 27-Mar-2012 • Originally posted on 27-Mar-2012 by Brandon Van 0
I also realized under the statistics page for irules that nothing has been counted even the default irules have nothing.
placeholder+image
USER ACCEPTED ANSWER & F5 ACCEPTED ANSWER
Updated 27-Mar-2012 • Originally posted on 27-Mar-2012 by Brandon Van 0
Thanks for the help, i resolve my problem, but now i have another one. I will create a new string with it.
;