10-15-2010 05:36 AM - edited 03-06-2019 01:32 PM
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
10-15-2010 05:38 AM
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
10-15-2010 05:46 AM
thank you for quick reply yramdoss..
10-15-2010 05:54 AM
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
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