2

I know that the layer 2 doesn't understand IP, and the broadcast domain is same.

Why can't devices talk, how does it happen?

  • Are you referring to two subnets on the same VLAN, from your previous question? – Ron Trunk May 7 '17 at 19:41
  • yes in the same default VLAN – Nina May 7 '17 at 19:44
  • Sorry for the hairsplitting, but your question asks for, why devices in different subnets can't talk. The answer is: yes, they can talk. Now I am sending this comment from a very different subnet as the subnet of the stackexchange frontend serverfarm. My device, and the device of the SE frontend gateway, can communicate without any problem. – peterh May 8 '17 at 0:46
  • Furthermore, "and the broadcast domain is same.". Same as what? There is not even "broadcast domain" in l2. There is a broadcast address, which is ff:ff:ff:ff:ff:ff on Ethernet. – peterh May 8 '17 at 0:48
  • Peter, surely you they can talk usin routers but I.mean with out router. – Nina May 8 '17 at 0:49
6

Devices in different subnets can communicate. That is the purpose of a router. Routers route packets between different networks.

Even if devices in different networks are on the same layer-2 broadcast domain, you need a router to let the devices communicate at layer-3. That is because each host will compare the destination layer-3 address and its own layer-3 address and mask to see if they are on the same network. If the destination host is on a different network, the host will send the packets in layer-2 frames to its configured gateway (router).

The host must assume that the destination network could be across the world from its network, and the gateway is the host on the network that knows how to forward packets toward the destination network.

  • Thanks, this is Absolutely clear , I have a simple question ,if there are many networks on the switch they are considered in the same domain and broadcasts will flow to all networks ? – Nina May 7 '17 at 19:53
  • 3
    That depends. A VLAN is a broadcast domain. If you have multiple VLANs on one switch, then you have multiple broadcast domains. If you have multiple networks on the same VLAN, then layer-2 broadcasts will reach every host on the VLAN, regardless of the network. Hosts on a different network will ignore layer-3 broadcasts on a different network, but the broadcast will still interrupt every host. You use VLANs to break up the broadcast domains. – Ron Maupin May 7 '17 at 19:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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