Forum Discussion

Thales_92506's avatar
Icon for Nimbostratus rankNimbostratus
May 14, 2012

iRule to restart a server (pool member) when marked down

Is there a way that an iRule can restart a server (pool member) when it is marked down?

By sending a restart command or anything like that..






4 Replies

  • Hi Thales,



    The functionality that you are describing would best be contained within the Server Health Check and not an iRule.



    iRules are event driven, so a client would have to hit the Virtual Server that the iRule was applied to and then the iRule would have to trigger an event like actvive_members in order to detect the status of the pool members.



    You can always submit a feature request to F5. I can see where it would be something useful...



    Hope this helps.
  • You could configure an external monitor that could connect to the server and restart it when the monitor fails.


  • Ok. In case of a get eav (, how could i connect to the server and send this command?
  • Thales,



    in the example you provided linux command:


    curl -fNs http://${IP}:${PORT}${URI} | grep -i "${RECV}" 2>&1 > /dev/null


    is used.



    Unfortunatelly you can't reboot the server useng "curl".


    You would have to create script in ie. bash which will login to the server and perform reboot.