0

I have a PC connected to a switch connected to a router : why does the show arp returns a different IP than the PC's gateway on the Switch ? :

PC $ arp -a | grep -w gateway
gateway (172.16.15.1) at 00:00:5e:00:01:01 [ether] on bond0
PC $

Switch#show mac-address-table address 00:00:5e:00:01:01

Codes: *N - VLT Peer Synced MAC
*I - Internal MAC Address used for Inter Process Communication
VlanId     Mac Address           Type          Interface        State
 4      00:00:5e:00:01:01       Dynamic         Te 0/0          Active
 6      00:00:5e:00:01:01       Dynamic         Te 0/0          Active
 8      00:00:5e:00:01:01       Dynamic         Te 0/0          Active
 9      00:00:5e:00:01:01       Dynamic         Te 0/0          Active
 166    00:00:5e:00:01:01       Dynamic         Te 0/0          Active
Switch#show arp macaddress 00:00:5e:00:01:01

Protocol    Address         Age(min)  Hardware Address    Interface      VLAN             CPU
---------------------------------------------------------------------------------------------
Internet    172.17.10.1         192   00:00:5e:00:01:01   Te 0/0         Vl 6             CP
3
  • Please make sure that you include sufficient detail in order to answer your question. As it is, it's completely unclear what the scenario looks like, what you were expecting and why. Also, there's no reason to obscure private IPv4 addresses since literally everyone uses those.
    – Zac67
    Oct 24, 2022 at 12:51
  • @Zac67 Got it, let me update my question ...
    – SebMa
    Oct 24, 2022 at 12:54
  • A MAC address table is not an ARP table. You cannot compare the two. They have completely different information.
    – Ron Maupin
    Oct 24, 2022 at 13:15

1 Answer 1

1

As it seems, the PC is connected to a different subnet (the gateway 172.16.15.1 might indicate 172.16.15.0/24) than what the switch shows for VLAN 6 (172.17.10.1 might indicate 172.17.10.0/24).

Since a router is connected to multiple subnets, that one seems to be connected to both subnets, with different IP addresses (necessarily) but using the same MAC address on both (entirely legal).

Note that there must be a unique mapping from an IP address to a MAC address, but a single MAC address may be mapped by multiple IP addresses, even on different subnets as in your case.

Also note that the switch's ARP cache is only populated and relevant when it's routing (for a layer-3 switch) or used by management. A plain layer-2 switch uses neither IP addresses nor ARP (except for management).

2
  • Hi, you said that one seems to be connected to both subnets, with different IP addresses (necessarily) but using the same MAC address on both. Was this done automatically by the L3 switch gateway or was this done manually by a network administrator ?
    – SebMa
    Oct 25, 2022 at 7:46
  • Any connection needs to be made physically or logically (by configuration) by a network admin. Nothing is connected "automatically by the L3 switch gateway" - I'm not sure if I understand your question correctly and what you mean though as we know nothing about your network.
    – Zac67
    Oct 25, 2022 at 8:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.