03-12-2019 11:34 PM
Hi,
I'm planning a auto backup script with EEM on our nexus 7K switchs, but the "action xx info" command not support.
Can someone tell me what version support this command?
The following is the output of N7K.
----------------------------------------------------------------------------------N7Ka
N7Ka(config)# event manager applet Backup-Running-Config-To-TFTP
N7Ka(config-applet)# description Backup-Running-Config-To-TFTP
N7Ka(config-applet)# event syslog pattern "%SYS-5-CONFIG_I: Configured from"
N7Ka(config-applet)# action 0.1 info type routername
^
% Invalid command at '^' marker.
N7Ka# sh ver | i ver
the GNU General Public License (GPL) version 2.0 or the GNU
BIOS: version 3.22.0
kickstart: version 6.1(3)
system: version 6.1(3)
System version: 6.1(3)
----------------------------------------------------------------------------------N7Kf
N7Kf(config)# event manager applet Backup-Running-Config-To-TFTP
N7Kf(config-applet)# description Backup-Running-Config-To-TFTP
N7Kf(config-applet)# event syslog pattern "%SYS-5-CONFIG_I: Configured from"
N7Kf(config-applet)# action 0.1 info type routername
^
% Invalid command at '^' marker.
N7Kf# sh ver | i ver
the GNU General Public License (GPL) version 2.0 or the GNU
BIOS: version 3.1.0
kickstart: version 7.2(1)D1(1)
system: version 7.2(1)D1(1)
System version: 7.2(1)D1(1)
03-14-2019 07:32 AM
i have done some script same based on snmp
event manager applet NX-OS_Conf_TFTP_Backup
event snmp oid 1.3.6.1.4.1.9.9.109.1.1.1.1.6.1 get-type exact entry-op le entry-val 12345 poll-interval 120
action 1.0 cli command enable
action 2.0 cli copy run tftp://10.10.9.9
action 3.0 syslog priority notifications msg Running_Config_Backup_TFTP_Complete
03-14-2019 07:43 AM
I have tested based on the event you looking it works.
event manager applet BB_TFTP
event syslog pattern ".*%SYS-5-CONFIG_I.*"
action 1.0 cli command enable
action 2.0 cli copy run tftp://10.10.9.9
action 3.0 syslog priority notifications msg Running_Config_Backup_TFTP_Complete
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide