Two PCs on the Same Switch Cannot Ping
intermediateDepartment VLAN Lab
One access switch · four isolated broadcast domains · port map follows the supplied lab
Situation
PC1 and PC2 are connected to SW1. Both links are up. PC1 is 192.168.10.10/24; PC2 is 192.168.10.20/24. They should be local neighbours, but ping fails.
SW1# show vlan brief
VLAN Name Status Ports
10 SALES active E0/1
20 MRKT active E0/2
Your task
Before opening the answer, decide: is this an IP-routing problem, an ARP problem, or a VLAN membership problem? Which single command above gives the strongest clue?
Think through the packet
PC1 sees PC2 as local because both addresses are /24, so PC1 sends an ARP broadcast. SW1 does not flood that broadcast from VLAN 10 into VLAN 20. PC1 therefore cannot learn PC2’s MAC address.
Root cause
E0/1 and E0/2 are in different VLANs even though the IP addresses suggest the hosts belong to the same IP subnet. The Layer-2 design and Layer-3 addressing disagree.
Fix
Put both hosts in the intended VLAN, or redesign addressing/routing if they truly belong in different VLANs. Never “fix” this by randomly changing the gateway.
Verification
show vlan brief → clear ARP cache if needed → ping again → inspect show mac address-table dynamic.