Lot people have some difficulties understanding this concept of collision Domain and Broadcast Domain. The explanations i see most of the time are not easy to understand. Before i diving into the subject, i want to talk about three type of network devices.
First let’s start with the Hub. The Hub can interconnect devices in our network just like you see in this figure below.
As you see i have three computers connected to the Hub. For example if PC1 send a message to PC2. All the devices connected to the Hub will receive the message even though the message is not destined for them. So the Hub has no intelligence of identify the devices so it just send the messages it gets out all its ports except the one it has come from. Based on the Hub’s behavior , PC1 and PC2 cannot send message at the same time otherwise there will be a collision. That’s why we say all the devices connected to the Hub belong to the same Collision domain or we can say the Hub represent One Collision Domain.
Now let’s take a look at the Switch. As you see in this figure
i have three PCs connected to the Switch. Here if PC1 send a message to PC2. PC3 will not receive the message. Unlike the Hub the Switch can recognize a device based on the mac-address. So PC1 and PC2 can send message at the same time and there will be no collision. That’s why we say each port on the Switch represent a collision domain. So with the Switch the number of collision Domains is equal to the number of ports on the Switch. However there is a message that the Switch cannot filter. This message is called a Broadcast message. So a Broadcast message sent to the Switch will go out all its port except the one it has come from. So we can conclude to say that the Switch represent by default a Broacast Domain.
Finally let’s take a look at the Router. As you see in this figure
i have computers connected to 2 Switches which are connected to a router. If a PC connected to Switch1 send a Broadcast message. That message will go to all the devices connected to that Switch but it will not get to the devices on the right side of the Router. So we can say that each port on the router represent a Broadcast domain.
So to recapitulate i will say devices on same collision domain cannot send message at the same time or there will be a collision.A broadcast message sent in a Broadcast domain will reach all the devices that share that domain.