03-16-2009 10:45 AM - edited 03-06-2019 04:37 AM
So we have a very strange connectivity issue. To troubleshoot down i would like to have the outputs of "show arp" and the output of "show mac-address-table" before and after this connectivity issue happens. The connectivity issue doesnt last long so it is hard to get into the 2 core L3 switches and get this info in a quick enough time. Is there a way to automate this process so say the switch will send the output of those to commands to a tftp server or a syslog etc every say 10 minutes or something
03-16-2009 11:19 AM
Hello Mike,
you need to use a specialized scripting language like TCL/TK with Expect that allows to automate login to device to send commands and to get output back.
see
http://www.activestate.com/activetcl/
Hope to help
Giuseppe
03-16-2009 12:32 PM
Hello Mike,
Check this out - I used this.
http://blog.ioshints.info/2007/08/example-tcl-script-with-command-line.html
Mat
03-16-2009 02:28 PM
You could try to automate this with an EEM Applet. Show arp and show mac-address-table are executed every 10 minutes with the below script and the output is stored in your log buffer of your router. If you have syslog server setup then that output can be exported.
However, the caveat is that your log buffer might get filled quickly.
event manager applet test
event timer watchdog time 600
action 1.0 cli command "show arp"
action 2.0 syslog msg "$_cli_result"
action 3.0 cli command "show mac-address-table"
action 4.0 syslog msg "$_cli_result"
03-17-2009 01:57 PM
Thanks guys. I will give your ideas a shot when i have some time.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide