Forum Discussion

4 Replies

  • destination d_prog { program("/bin/script" template("<$PRI>$DATE $HOST $MSG\n");

     

    http://www.balabit.com/downloads/files/archived_documents/syslog-ng-2.0-guides

     

    • Kevin_Davies_40's avatar
      Kevin_Davies_40
      Icon for Nacreous rankNacreous
      Given the right logging filter looking for member down messages you could get a program to run on BIGIP using the above destination ~ YMMV
  • Thank you for the answer, so basically the idea is to generate syslog trap on F5 and use that to trigger a script ?

    What about below code:

    destination d_prog { program("/bin/script" template("<$PRI>$DATE $HOST $MSG\n");

    is it an iRule ?

    Thank you

  • so basically the idea is to generate syslog trap on F5 and use that to trigger a script ?

     

    yes. you can execute script using syslog-ng (Kevin's suggestion), alertd or icall.

     

    this is alertd.

     

    sol14397: Executing a command or custom script based on a syslog message

     

    http://support.f5.com/kb/en-us/solutions/public/14000/300/sol14397.html

     

    and this is icall.

     

    iCall - All New Event-Based Automation System by Jason Rahm

     

    https://devcentral.f5.com/articles/icall-all-new-event-based-automation-system

     

    is it an iRule ?

     

    no, it is syslog-ng configuration.

     

    to run script remotely, you may check if plink is usable.

     

    Plink

     

    http://en.wikipedia.org/wiki/Plink