Hello and welcome back to this video on collision domains, broadcast domains, and VLANS. Let’s start by talking about a collision domain.
So first up, what is a collision domain? According to one of the definitions, collisions are confined to a physical wire over which data is broadcast. Because the physical wires are subject to signal collisions, individual LAN segments are known as collision domains. There’s another definition that says- a collision domain is the part of the network where packets can collide with one another.
My definition is the one that you see at the last, simply put, a collision domain refers to how many devices can send data at the same. Now that’s how I remember what a collision domain is, how many devices can send data at the same time. So when we talk about collision domains on a hub, think about a hub for a second, on a hub there’s only one device that can send data at any time. So a hub is one collision domain. When we talk about a switch, every device that’s connected to the switch, can send data at the same time.
Switches collision domain
So if you have a switch with four ports, or four devices connected, that is four collision domains. When we talk about a router, it’s again the same. The number of collision domains on a router is equal to the number of devices connected, or the number of ports on that router. So you may have a question on the examination that shows you a diagram, or that says there are eight devices connected to this switch, how many collision domains do you think does the switch have? So remember, on a hub, it’s just one collision domain, on a router or on a switch, the number of collision domains is always equal to the number of ports, or the number of devices connected.
Now let’s talk about a broadcast domain. On a layer two network, broadcasting refers to sending traffic to all nodes on a network. Layer two broadcast traffic stays within a local area network boundary, knows as the broadcast domain. Another definition says, a broadcast domain is a logical division of a computer network, in which all nodes can reach each other by broadcast at the data link layer. Simply put- a broadcast domain indicates how far can a broadcast reach on a network.
Let’s talk about a hub, on a hub if one devices sends a broadcast, every device that is connected to the hub, receives the broadcast. So that’s one broadcast domain. When we talk about a switch, when one device sends a broadcast, every device connected on that switch receives the broadcast, so it is one broadcast domain. When we talk about a router, it’s likely different. So we have this diagram over here, there’s a router in the center, and there are four devices that are connected to the router.
When Host A sends a broadcast, the broadcast reaches the port on which it is connected, which is fe-0/0/0. Now routers are designed to drop broadcasts, a router never forwards a broadcast. So when the broadcast reaches port fe-0/0/0, it is going to drop the broadcast. So that is one broadcast domain. The same applies with Host B, when Host B sends a broadcast, and when the broadcast reaches port fe-0/0/1, the broadcast is going to be dropped, so that’s one more broadcast domain.
And then Host C and Host D are also their own broadcast domains. So on a router, the number of broadcast domains, is equal to the number of ports. Every port is a broadcast domain on its own. This could again be a question on the examination. They might give you a diagram, or they might ask a question that says, there are a couple of devices connected to the router, and a couple of devices connected to the switch, identify the number of broadcast domains. So remember, on a hub and on a switch, it is just one broadcast domain.
On a router, the number of broadcast domains is equal to the number of ports, or the number of devices connected. Alright, so now let’s talk about VLANS. First up, why do we need VLANS? A switch is a single broadcast domain, just like we discussed right now. This means, when a broadcast is sent, the broadcast is received by every device connected to the switch. Now this is not a problem when few devices are connected to the switch. However, as more devices connect to the switch, broadcasts start to become a menace, because broadcasts can consume network bandwidth.
Additionally, you may want to logically separate devices on the same LAN into different groups. And lastly, you may also want to apply Quality of Service to different types of traffic. For example, you may want to prioritize voice traffic over normal data traffic. So, let’s understand what VLANS are. A VLAN, or a Virtual LAN is a logical separation of devices on the same local area network, or on the same switch. It allows you to divide a LAN segment into multiple logical LANS, also known as Virtual LANs.
Very important, each VLAN is a different network with separate layer three addressing. And very important, each VLAN is a different broadcast domain. So if you have a switch with the default configuration, it’s just one broadcast domain. But if you have a switch which has been divided into multiple VLANS, the number of broadcast domains equals the number of VLANs on that switch. Alright so by default when you have a switch, it is just one layer three network, right? So in this diagram I have a switch, which just has devices on a single network, which is 192.168.1.0/24.
This switch can be divided into multiple networks using VLANs. So on the left-hand side you have VLAN one, which is 192.168.1.0/24, and on the right-hand side you have VLAN number two, which is 192.168.2.0/24. Notice both of these are different layer three networks. By default, VLANs do not talk to each other. You need to introduce a layer three device to make them talk. For example, if I wanted to make VLAN one and VLAN two talk to each other, I would have to introduce a layer three device like a router.
Router will be responsible for routing the packets between the VLANs. Also remember, VLANs can span multiple switches. So we have switch one on the left-hand side, which has two VLANs, VLAN one is 192.168.1.0/24, and VLAN two is 192.168.2.0/24. I can connect switch one with switch two, and I can have my VLANs extend over to switch two. So I can have the same VLANs, which is VLAN one and two, carried over or extended over to switch two, so switch two also has the same VLANs, which is VLAN one and VLAN two.
So what happens is, VLAN one on switch one can automatically talk to VLAN one on switch two. But if you wanted to make two different VLANs talk, in that case you would have to introduce layer three routing. Some more information, by default, VLANs do not talk to each other. A layer three device such as a router is required to route traffic between VLANs. Different policies can be applied to traffic coming from different VLANs. For example, you can apply a policy that prioritizes voice traffic over data traffic.
Voice traffic on VLANS
Now the assumption is, voice traffic is on a different VLAN, and data traffic is on a different VLAN. When a switch is divided into different VLANs, we need to have a way to identify or differentiate VLANs. So, each VLAN is identified by a unique 802.1Q ID, which is also known as a tag. VLAN IDs can range from VLAN zero, to VLAN 4095. But remember, VLAN ID zero and 4095 are reserved, they cannot be used for production traffic.
The maximum number of VLANs that you can create on a switch depends on the model of the switch. For example, if you have a higher end switch, it may allow you to create more number of VLANs, compared to a switch that has a lower model. If you want to know the maximum number of VLANs that are supported, you can use the following configuration mode command. The command goes like this, set VLANs, and then you give a VLAN name, and then you give a VLAN ID, followed by a question mark. You’ll get to know the number of VLANs that are supported on that switch.
We are gonna try this command when we get to the labs, for now you can just make a note of this command. In order to identify packets that belong to a VLAN, Ethernet packets have two fields. So think about this, when I have my switch that has been divided into multiple VLANs. I need to have a way to know which packet belongs to which VLAN. And to do that, the Ethernet packets, or the Ethernet frames have two fields that help us identify the VLAN to which the traffic belongs.
The first field is known as Tag Protocol Identifier, or TPID EtherType field, the second one is VLAN ID field. When a packet is generated on a VLAN, the TPID ETherType field has a value of 0x8100. The VLAN ID field has the actual 802.1Q ID. Or in other words, the actual VLAN ID, which identifies the VLAN to which the packet belongs.
Now if your switch only has the default VLAN, which means no additional VLANs have been configured, packets have the default 802.1Q tag. These packets are considered to be untagged. So, that’s it for this lecture guys, let me know if you have any questions. If not, I’d like to thank you for watching, and I’ll catch you in the next lecture.
Latest posts by Hamza Arif (see all)
- Understanding the Internet, intranets, and extranets - August 17, 2018
- Exploring network collisions, CSMA/CD, and CSMA/CA - August 16, 2018
- Client server and peer-to-peer connections - August 14, 2018