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

EEM script issue

nawas
Level 4
Level 4

I'm using this EEM script to shut down a port when a cable is pulled or port goes down for any other reason. It works to shut down the port but I'm facing the following problem

1. I have a "wait 120"configured but it never re-enable the port after 120 seconds

2. If I attempt to re-enable the port manually it immedeately shuts it down using the EEM unless I remove the event manager configuration.

Please advise.

event manager applet interface_down

event syslog pattern ".*UPDOWN.*FastEthernet0/4.* changed state to down"

action 1.0 syslog msg "Interface FastEthernet0/4 has gone down"

action 1.1 cli command "enable"

action 1.2 cli command "conf t"

action 1.3 cli command "Interface FastEthernet0/4"

action 1.4 cli command "shut"

action 1.5 cli command "end"

action 1.6  syslog msg "Interface FastEthernet0/4, changed state to administratively down"

action 1.7 wait 120

action 2.1 cli command "enable"

action 2.2 cli command "conf t"

action 2.3 cli command "Interface FastEthernet0/4"

action 2.4 cli command "no shut"

action 2.5 cli command "end"

4 Replies 4

singhaam007
Level 3
Level 3

Hello,

You can use debug event manager action cli to see where the actually problem is . then use show logg .

It may be authorization issue. You may be need to add

event manager session cli username "twdadmin"

if there is any user name involve.

Please try and let me know.

thanks

singhaam007
Level 3
Level 3

try to change ur applet

https://supportforums.cisco.com/thread/2157917

thanks

nawas
Level 4
Level 4

Tried this already but it crashed my router as soon as pulled the cable, I'm not too good in tcl and prefer to use applet instead.

Sent from Cisco Technical Support iPhone App

Any one else have an idea why EEM is disabling port when i attempt to re-enable it?

Item#2 in my original post. The only work around I see it to completely remove the EEM configuration, re-enable the port and re-apply EEM configuration, anything wrong with my applet?

Review Cisco Networking for a $25 gift card