A virtual LAN (Local Area Network) is a logical subnetwork that can group together a collection of devices from different physical LAN.
Imagine that we have different departments on your company and you want to separate each department based on their employees. So, with the VLAN concept you can create a VLAN and then assign different ports to these VLANs.
In the above picture, we have 3 departments, each of which is assigned to unique VLAN. let’s configure switch:
For viewing created VLANs, we enter this command:
VLAN 1 is a default VLAN in Cisco devices. VLAN from 1002-1005 are for other protocols. VLAN from 1006- 4094 is called Extended VLAN.
In above picture, a PC in VLAN 10 is connected to port Fa0/1 switch. So, we can write this command to access port Fa0/1 to VLAN 10:
Now, if we enter show vlan:
Now we do it for other ports:
and the result is:
By default in Cisco switches , Vlan 1 is a native Vlan. It means, untagged traffic carries in this vlan. We’ll know how to change Native Vlan.