cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2282
Views
0
Helpful
3
Replies

how to shut no shut interface of switch using(EEM) Script

khaled
Level 1
Level 1

Dear community Member,

I'm new for creating scripting for EEM and below is my situation, need your support.

Present I'm using 3560 switch, one of  the switch port(FA0/1) has added  Cisco Access point(PoE), actually what happening daily this Access point getting struct when I'M doing the switch port (FA0/1) shut  then no shut it is working fine .

 

So my question is i need script, that should continuously ping the IP off the Access point if the IP will drop 4 packets the switch do shut  and then no shut for that I need the script, Please help me.

 

if it is not possible please provide the batch file, which will ping the particular IP if 4 packet drops it will telnet the switch and go to the interface do shut no shut 

 

Note: 

 

instead of mentioned 3560, I mentioned 2960 now corrected it  please provide the script.

3 Replies 3

Joe Clarke
Cisco Employee
Cisco Employee

The 2960 series switches do not support full EEM.  We recently tried to determine a workaround for such switches to do automated tasks like this, but it was not possible.  You'll need a 3560 series switch at least to be able to execute EEM policies.

instead of mentioning 3560, I mentioned 2960 now corrected it  please provide the script.

Check this post out. It's solves almost the same problem that you have:

https://supportforums.cisco.com/discussion/10794236/shut-interface-if-no-ping-response-using-ip-sla-eem

You'll need to add an additional action to the EEM however. You would need to add an action to have it no shut the interface it just shut. After that, you should be all set.

 

Side note, something else is causing your link to drop off. An EEM would be a band-aid, not a solution. I'd perform additional testing to see what's causing it. Best of luck on this! :)