Let's say I have three different hosts connected by a Layer 2 Switch:
A) IP 1.0.0.1, Subnet 255.255.255.0,
B) IP 1.0.0.2, Subnet 255.255.0.0,
C) IP 1.0.1.1, Subnet 255.255.255.0,
Who would a broadcast message (like an arp request) from each machine reach? I know that if the arp tables were pre-generated, you could send non-broadcast packets directly from A-> B, B->A, and B->C , while A->C, C->A, and C->B would be send to the default gateway and fail.
I know that connecting subnets like this is non-ideal, I was just wondering how communications work when it's done accidentally.
As a second question, let's say that they're now connected by a Layer 3 Switch (A Router?) Am I correct in thinking that a ping from B to C would go from B -> C, and the response would go from C -> R -> B?
Best Answer
Ethernet broadcasts from any host will reach any host connected to the same switch/VLAN. IP broadcasts will not reach any of those hosts, because each host has its own broadcast IP address.
Yes, if we have static ARP entries for all the hosts, that will be true.