ARP table with logical and physical interfaces

In a layer-3 switching environment, the ARP table displayed with the show arp command lists the logical (L3) interfaces, for example the VLAN or BVI interface. This Tcl script displays the logical as well as physical interface associated with each IP/MAC address.

Martin Hecko gave me the idea for this script and helped to test it on a Catalyst switch. Thank you!

You can find more Tclsh-related information in the Tclsh on Cisco IOS tutorial. Sample Tclsh scripts are available in the Tclsh script library. If you need expert help in planning, developing or deploying Tclsh scripts in your network, contact the author.

4 comments:

  1. Hi Ivan

    Its a gud scrip. Do you have any script which can tell me how many routers are in my particular area. e.g If i am having a router with 3 areas and i wnat to know how many router ids in each area with their ip address.
    I have one more query , yesterday iw as reading your books mpls vpn arch, in which you had mentioned that on Bi-Dir MVPN data mdt wonot work. I have a query If we implement BSR then does it create the same problem or not and with this can we deliver the extranet mvpn.
    regards
    shivlu

    ReplyDelete
  2. The OSPF idea is good :) You'll get the script ... just give me some time ;)

    As for the MVPN question, I have to think it through; I'm no multicast guru.

    ReplyDelete
  3. Hi,

    I'm just starting to work with tcl scripts. I found the arp.tcl and it workt fine. However, when I execute the command on our Cisco Catalyst 6513 running on IOS s72033-advipservicesk9_wan-mz.122-18.SXF14.bin we do not see the physical interface.

    If I run a show -mac-addres-table command myself teh output looks like:

    vlan mac address type learn age ports

    --------------------------------------------------------------------------------
    +----------------+--------+-----+----------+--------------------------
    606 3333.0000.0001 static Yes - Switch,Stby-Switch
    607 3333.0000.0001 static Yes - Switch,Stby-Switch
    602 001b.7803.5faa dynamic Yes 0 Gi9/42
    669 0013.211f.f061 dynamic Yes 5 Po3
    11 7a9f.b000.2003 dynamic Yes 0 Gi10/27
    74 0013.216b.ab27 dynamic Yes 75 Gi9/12
    18 0017.a48d.546b dynamic Yes 0 Gi9/6


    Etc. I really want to see the Gix/x entries back in the arp output. That would save me tons of time. Thnax in advamce for your reaction.

    ReplyDelete
  4. dhcp snooping feature on L3 switch can get you the same information as arp.tc script.
    It need configure dhcp snooping, wait filling of dhcp snooping database. Enter:
    sh ip dhcp snoop bin

    ReplyDelete

You don't have to log in to post a comment, but please do provide your real name/URL. Anonymous comments might get deleted.

Ivan Pepelnjak, CCIE#1354, is the chief technology advisor for NIL Data Communications. He has been designing and implementing large-scale data communications networks as well as teaching and writing books about advanced technologies since 1990. See his full profile, contact him or follow @ioshints on Twitter.