Sunday, April 6, 2008

EEM - Watchdog timer

This EEM example applet will trigger every minute (60 seconds):

EEM Applet:
event manager applet goober
event timer watchdog time 60
action 1.1 cli command "enable"
action 1.2 cli command "del /force flash:show_tech"
action 1.3 cli command "show clock | append flash:show_tech"
action 1.4 cli command "show version | append flash:show_tech"
action 1.5 cli command "show run | append flash:show_tech"
action 1.6 cli command "more flash:show_tech"
action 1.7 syslog msg "Sending goober output..."
action 1.8 mail server $_email_server to $_email_to from $_email_from subject "Goober Output" body "$_cli_result"
action 1.9 syslog msg "Goober output sent!"