VLAN (Virtual Local Area Network)
Broadcast Domain Collision Domain
HUB 1 1
Bridge 1 4
Switch By default 1 Each port contains separate collision domain
Why you have to create VLAN?
If you have one broadcast domain, than there is no privacy of any department in the company. There are two solutions to solve this problem. One is, provide a separate switch to each department, but this would increase cost. And the other solution is, you have to break one physical broadcast domain to multiple logical broadcast domains.
One VLAN already exist on every switch and this VLAN is known as management VLAN. By default each port of switch is member of VLAN 1. #Show VLAN is a command to check how many VLANs created on the switch, and port’s membership with these VLANs.
How to create VLANs?
By default, same VLANs can communicate with each other. For example, VLAN 2 is for IT department, than you have to create VLAN 2 on every switch in company, for IT department. You can create VLANs only on the basis of numbers, not on the basis of names, for example (VLAN 2, VLAN 3, VLAN 4). But you can use names after numbers, for example (VLAN 2 IT, VLAN 3 HR).
Trunk: A link through which two switches connect with each other is known as trunk. And cable which is use to connect same devices is known as cross over cable.
Types of switchports:
- Access ports: Those ports which are members of one VLAN at a time, are known as access ports.
- Trunk ports: Ports through which traffic of multiple VLANs passed at a time, are known as trunk ports.