Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

Layer 2 Switch arp table

Hi All,

i know L2 switch doesn't understand of IP.So how i can see the ip address in "sh arp" print?

swXXXX1#sh arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  172.1.9.79             2   0012.3f2b.f470  ARPA   Vlan1
Internet  172.1.9.65            21   0000.5e00.0101  ARPA   Vlan1
Internet  172.1.9.81             1   0012.3f2b.f191  ARPA   Vlan1
Internet  172.1.9.80             4   0012.3f2b.ec41  ARPA   Vlan1
Internet  172.1.9.1              0   0011.43ee.b9fd  ARPA   Vlan1
Internet  172.1.9.100            -   0023.ead3.1f40  ARPA   Vlan1

3 REPLIES
Cisco Employee

Re: Layer 2 Switch arp table

Because, this switch in discussion has an SVI in vlan 1.

As long as you have a layer3/SVI interface, it does ARP and builds ARP cache for devices in same vlan/subnet.

- Yogesh

New Member

Re: Layer 2 Switch arp table

thank you for quick reply yramdoss..

Hall of Fame Super Blue

Re: Layer 2 Switch arp table

heavenix_1982 wrote:

Hi All,

i know L2 switch doesn't understand of IP.So how i can see the ip address in "sh arp" print?

swXXXX1#sh arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  172.1.9.79             2   0012.3f2b.f470  ARPA   Vlan1
Internet  172.1.9.65            21   0000.5e00.0101  ARPA   Vlan1
Internet  172.1.9.81             1   0012.3f2b.f191  ARPA   Vlan1
Internet  172.1.9.80             4   0012.3f2b.ec41  ARPA   Vlan1
Internet  172.1.9.1              0   0011.43ee.b9fd  ARPA   Vlan1
Internet  172.1.9.100            -   0023.ead3.1f40  ARPA   Vlan1

Another way to look at this is that a L2 switch does not look at or use IP addresses for packets going through the L2 switch from one destination to another ie. packets that have a src and destination  IP address that is not an address on the switch. For these sort of packets, which make up the majority of the traffic, only the mac-address is used and only the cam table is consulted.

However, just like a client PC, L2 switches still have a TCP/IP stack that is used for packets going to and from the switch ie. packets that have a src or destination IP address of the switch itself. In your case you have a L3 vlan interface on this switch used for management.. Just like a client PC if the switch wants to send packets to any other address in vlan 1 or to it's default-gateway in vlan 1 it will use arp and resolve the IP to mac-address so it can build the IP header

Just to be precise, if a client in vlan 1 sends a packet to another client in vlan 1 then the switch would still only look at the mac-addresses. It is only if the switch itself needs to send packets in vlan 1 that it would do an arp for the destination IP address.

Jon

2070
Views
0
Helpful
3
Replies