Learn F5 Technologies, Get Answers & Share Community Solutions Join DevCentral

Filter by:
  • Solution
  • Technology
Answers

Call a web page when a pool member (node) is set down by a monitor

i have a pool with 3 nodes checked by a monitor. When a pool member is set down by the monitor I need to trigger an iRule to call an external web page to let it know that that node is down and, in my case, recycle an IIS AppPool. The dream should to be able to directly call a script on the failed node from LTM to do the recycle, but even the first solution could be ok. Can anyone help me on that?

Thanks in advance. Stefano Chiesa

0
Rate this Discussion

Replies to this Discussion

placeholder+image

(There was an "Hello all" at the beginning....disappeared...sorry)

0
placeholder+image

Of course the iRule must be called only the first time the node is set down by the monitor!

0
placeholder+image

Anyone?

0
placeholder+image

You can use below iRule to send a maintenance page to users when your servers are down.

For calling a script on when an event occur(pool/node down), you can research on a feature called iCall to have event based script execution

#This I-rule will alert us if a all Web servers are down, It will return an apology page to client
#Apology page message

when LB_FAILED {
if { [active_members mypool] < 1 } {
# Log and direct the client to Maintenance Page
log local0.notice "!!Attention Required - mypool does not have any active member.!!"
HTTP::respond 200 content {
      <html>
         <head>
            <title>Apology Page</title>
         </head>
         <body>
<center>    We are sorry, but the site you are looking for is temporarily out of service.<br>
         </body>
      </html>
   }
}}

/Amanpreet

0
Comments on this Reply
Comment made 18-Jul-2016 by Gestione Reti WKI 106

Thanks a lot Amanpreet, but this is not what I need. When a node is down I need to know what pool and what node went down and I don't need to warn the client with an apology page but instead call an internal web page on another server (passing the failed server IP) than can put in place scripts to recover the failed server.

Thanks anyway for your time. Stefano.

0
Comment made 18-Jul-2016 by Gestione Reti WKI 106

Ah sorry, I lost the "iCall" part...

0