cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
727
Views
0
Helpful
4
Replies

EEM script on Nexus9K to send syslog if version changed

Veroniks23
Level 1
Level 1

hello!

i am interested to know if there is any way to create an EEM script that will send via syslog the verison of my NEXUS.

 

for example:

event manager applet VERISON_CHECK

event cli match "copy running-config startup-config"

-> and then i want it to execute the following command and send the result via syslog :

show ver | sec NXOS | sec nxos.

 

would appreciate any help, thank you. 

4 Replies 4

balaji.bandi
Hall of Fame
Hall of Fame

 try this :

 

action 1.0 cli command "show version | in "System version:""
action 2.0 regexp "version: (.*)\r" "$_cli_result" ver
action 3.0  syslog msg "nexus currect running version $ver"

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Thank you for your answer! 
it doesn’t work, NEXUS 9000 does not have this commands for EEM.

That’s my problem 

Apologies that did not work for you, what is the error you get, the EEM I gave was in general (let me test what is not working)

 

EDIT: you are right that the command regex not taking, Option only has here is to use TCL or Phython.

 

 

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Hello,

 

do you have network-admin user privileges on the Nexus ?

Review Cisco Networking for a $25 gift card