Collision Domain

This topic is to discuss the following lesson:

Thanku so much sir for your precious time and clear my point .
I want to know about how a switch negotiate to work in half duplex , if it work is they use CSMA CD or not ?
As i learn from somewhere switches uses single broadcast domain and separate collision domain for each port .
My question is they use same domain in both full duplex and half duplex .
How to check and configure half and full duplex in switch and router too ?
How to find that the device is half duplex or full duplex , is that happen on port configured ?

i want a brief explaination in this , hope you understand my query .

Regards
Shivam Chahal

Hello Shivam

In the past, we used hubs in order to connect Ethernet hosts to the network. This meant that any frame sent by one host would be received by all other hosts. Hosts would then check the destination MAC address to see if the frame belongs to them. If not, it would be discarded. Hubs present another problem as well which takes place if two or more hosts send a frame to the network at the same time. The result is a collision. The group of hosts that will be reached by a frame sent by one of the hosts is called a collision domain. So a hub. and all the hosts connected to it would constitute a collision domain. CSMA/CD is the mechanism used to coordinate how hosts in a single collision domain communicate with each other.

For small networks, this worked well, but as networks got larger, hosts would be overwhelmed with frames that do not belong to them, and they would spend too many resources discarding such frames. The occurrences of collisions also increase with the increase in the number of hosts.

A switch unlike a hub, functions such that each of its ports makes one collision domain. This means that a switch port, and the host it connects to are the only two devices within that collision domain. It looks something like this:

image

Now, if the communication between a host and the switchport is configured as half duplex, then there is the possibility of having a collision, because both the host and the switchport may try to send data at the same time. CSMA/CD must operate in this case. However, if you configure the communication to function in full duplex, which allows data to flow in both directions at the same time, then you have eliminated the possibility of having a collision completely.

Half and full duplex on both switches and routers is configured using the duplex command in interface mode. You can configure it as either full, half, or auto. Full and half force the port to function in that mode, but auto will allow the port to negotiate with the host.

It is best practice to keep the configuration in auto for hosts and to configure it as full for connections from switch to switch, or switch to router to avoid any negotiation errors. Half duplex should never be used unless necessary for compatibility with older devices.

You will find much more information in the following lesson:

I hope this has been helpful!

Laz

1 Like

Appreciate sir for clearing doubt as i study in deep and this silly question raised as i think logically and its practical implementation .

Sir , one more request please add topics of security too like FTD , Fire power and different vendor which are in market demand .

Thanks
Chaudhary Shivam Chahal

Hello Shivam

A little bit about Firepower is mentioned in the Virtualization Functions lesson. Even so, the primary focus of NetworkLessons is CCNA, CCNP ENCOR, CCNP ENARSI, and CCIE Enterprise certifications. For this reason, these security products, and products of other vendors are not included in any detail in the site. Only the Cisco ASA is included as a section due to the fact that it is quite popular.

I hope this has been helpful!

Laz

Hey, I’ve got a question regarding a ‘full duplex’ connection.
In the case where we have a switch connected to 4 hosts (one on each port), while using a full duplex connection on each one, do we still have 4 collision domains?
Since no collision could ever occur, there should be 0 collision domains on the network.
‘collision domain’ - a shared medium where simultaneous data transmissions collide with one another.

Hello Moshe

That’s an interesting question you bring up. Keep in mind that a collision domain is not defined by whether or not collisions actually occur. A collision domain is a segment of a network that is bordered by either a port on a router, or a port on a switch. Now if you happen to have a single host connected to a port on a switch, and it is in full duplex mode, collisions won’t occur, but the definition of the collision domain still stands.

This is because, if you connect a hub to that switch port, and connect multiple hosts to that hub as shown below, you are taking that same collision domain, and expanding it. Now it has has more hosts, and collisions can occur.

I hope this has been helpful!

Laz

1 Like

In my diagram, lets say that Pc1 is sending traffic to Pc2 and at the same time PC3 sending traffic to pc4. …will it be there any collision in this scenario ?

Hello Narad

Since you are using a hub in this diagram, all four hosts are on the same collision domain. This means that any time two or more devices try to “speak” at the same time, there will be a collision. Therefore, in the scenario that you describe, yes there will be a collision.

I hope this has been helpful!

Laz

Since CSMA/CD is disabled on interfaces on a switch and what if H3 and H4 on different collision domains send data at the same time, how is the collision avoided?

Hello Gokul

CSMA/CD is automatically disabled on full-duplex interfaces of a switch. This is done because by definition, on such an interface, there will never be a collision. If H3 and H4 on different collision domains send data at the same time, their interfaces on the switch can handle the incoming frames simultaneously. A collision will only occur if data is sent at the same time in the same collision domain. Since H3 and H4 are in different collision domains, no collisions will occur.

Now, what if H3 and H4 send data to H1 at the same time? The switch will deliver that data to H1 in sequence, on a first come first serve basis. If there are many pieces of data that arrive at the same time, then the switch will queue them and deliver them sequentially. Once again, no collisions can take place.

I hope this has been helpful!

Laz

Laz,

I have some devices operates on 10Mb/half duplex. I have connected them to my switch after I change the switchport to 10/half. They are currently working fine, however, I noticed that the “output errors” counter keeps going up every like 10 seconds. I have changed the cables but I am still having the same problem. Also , sometimes I see the “collision” counter goes up. Any idea? Thanks

Hello Eyad

This is normal behavior for a half-duplex link. In a half-duplex link, communication can only take place in one direction at a time. If both devices at both ends of the link begin to communicate simultaneously, a collision will occur. By definition, a half-duplex link is not a collision-free link. Conversely, a full-duplex link on a switch is a collision-free link.

So on a half-duplex link, you will see the CSMA/CD mechanism kick in to deal with detecting collisions and resolving them.

So don’t be alarmed by the collisions you see, since they are expected on such a link. Now if they are excessive and you are experiencing a degradation in service, then the problem may be elsewhere, but if they’re working fine as you mention, then there is nothing to worry about.

I hope this has been helpful!

Laz