[c-nsp] eem-script problem
Robert Hass
robhass at gmail.com
Thu Jan 3 05:30:04 EST 2019
Hi
I have below EEM script running at CSR1K:
event manager applet blah2 authorization bypass
event syslog pattern "%CLEAR-5-COUNTERS: .*"
action 0.01 syslog msg "blah2 script"
action 0.02 cli command "enable"
action 0.03 cli command "term exec prompt timestamp"
action 0.04 cli command "term length 0"
action 0.05 cli command "show clock"
action 1.01 cli command "sh interfaces gigabitEthernet 1 | include input
errors"
action 1.02 regexp "frame.*" "" $_cli_result
action 1.03 puts "match is $_cli_result"
"sh interfaces gigabitEthernet 1 | include input errors" returns line eg.:
2 input errors, 2 CRC, 0 frame, 0 overrun, 0 ignored
I want to have in syslog only 2 input errors, 2 CRC instead rest of line
How I can do that ?
Rob
More information about the cisco-nsp
mailing list