Cisco EEM Help

soni

n00b
Joined
Jan 27, 2009
Messages
34
I am trying to dump DHCP Database info to tftp. That's the easy part. The question I have is how do I use EEM to pull a timestamp, and then make the timestamp the file name that gets sent over tftp. My current EEM script is below.


event manager applet tx
event timer cron name DHCPD cron-entry "59 14 * * *"
action 1.0 cli command "en"
action 1.2 cli command "show ip dhcp database | redirect tftp://x.x.x.x/need_time_stamp.txt"
action 1.3 syslog msg "EEM cron DHCPD executed"
 
must have been a slow day a cisco TAC. they helped me with this. No variables allowed. But I can append to the original file using FTP. Script I used is below.


event manager applet tx
event timer cron name TAC cron-entry "59 14 * * *"
action 1.0 cli command "en"
action 1.1 cli command "terminal exec prompt timestamp”
action 1.2 cli command "show ip dhcp binding | append ftp://user:password@host/filename “
action 1.3 syslog msg "EEM executed"
action 1.4 cli command "no terminal exec prompt timestamp”
 
Back
Top