Forum Discussion

ken_wolff_10732's avatar
ken_wolff_10732
Icon for Nimbostratus rankNimbostratus
Sep 08, 2006

All Nodes Down Alert Message (SNMP?)

I have 2 radius servers behind a VIP. If both are down I have a "no nodes available" condition. How can I send an alert via SNMP or email to this effect? This alert used to be in 4.x but is not in 9.x as far as I can tell. Thanks, Ken

7 Replies

  • Deb_Allen_18's avatar
    Deb_Allen_18
    Historic F5 Account
    I don't see an alert or existing log message you could leverage, either.

    You could create a rule that logs a custom message, then create a custom alert for it:

    Example rule:
    when CLIENT_ACCEPTED {
       if { [active_members myPool] < 1 } {
          log local0. "No nodes available for virtual server [virtual name] at [IP::local_addr]:[TCP::local_port]"
          reject
       }
    }

    I'll leave it to you to figure out the custom alert definition & mapping if you think this might work for you.

    HTH

    /deb

  • Wow, that was easy. Your suggestion worked like a champ. I'm getting tons of repeat log messages, however (only one email, fotunately). Can I limit the number of log messages? Thanks, Ken
  • You could use the clock command to log the condition on the minute, or whatever interval you choose.

    
    when CLIENT_ACCEPTED {
      if { [active_members myPool] < 1 } {
        if { [clock format [clock seconds] -format {%S} ] eq "00" } {
          log local0. "No nodes available for virtual server [virtual name] at [IP::local_addr]:[TCP::local_port]"
        }
        reject
      }
    }
  • updated to move the reject statement out of the log condition.
  • Deb_Allen_18's avatar
    Deb_Allen_18
    Historic F5 Account
    You might also just try removing the local0. reference & use this log line instead:
     log "No nodes available for virtual server [virtual name] at [IP::local_addr]:[TCP::local_port]"
    Without the specific destination reference, you'll probably see the syslog summary messages instead:No nodes available for virtual server myVirtual at 1.1.1.1:80

    Last message repeated 42,1764 times.

    /d
  • How could I check for no nodes available for, say, a period of 5 minutes, rather than immediately? Thanks, Ken