×

Warning message

  • Cisco Support Forums is in Read Only mode while the site is being migrated.
  • Cisco Support Forums is in Read Only mode while the site is being migrated.

Q: How to create new CLI via EEM ?

Unanswered Question
Apr 10th, 2014
User Badges:

I would like to build an applet/EEM-script that would run in the CLI when performing an exec level CLI command, eg: "show foobar status". What is the best option to do this ?

 


 

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Loading.
Joe Clarke Thu, 04/10/2014 - 17:03
User Badges:
  • Cisco Employee,
  • Hall of Fame,

    Founding Member

You would register an applet using the CLI event detector with the "enter" keyword.  The enter keyword tells the parser not to deal with the command.  This will allow you to create your own command.  For example:

event manager applet test

 event cli pattern "^show foobar state" enter

 action 1.0 puts "FOO!"

Actions

This Discussion