The most viewed items
VLan is virtual local area network. It is mostly used to manage the hosts in the network. The example of how to configure VLan in Cisco Networking Devices is shown in the below with the picture together. I hope this example will be benefit for brothers and sisters who are learning Cisco Networking.
Switch 0
Creating VLan
en
config t
hostname tnw87.com
vlan 10
name IT_Department
vlan 20
name HR_Department
vlan 30
name Engineering_Department
end
Checking VLan (VLan we've created is working or not)
show vlan brief
Define Switch Ports
config t
int f0/1
no shut
switchport mode trunk
exit
int f0/2
no shut
switchport mode access
switchport access vlan 10
exit
int f0/3
no shut
switchport mode access
switchport access vlan 20
exit
int f0/4
no shut
switchport mode access
switchport access vlan 30
end
Save Configuration
copy run start
Router 0
en
config t
hostname tnw87.com
int g0/0
no shut
int g0/0.1
encapsulation dot1Q 10
ip address 192.168.1.1 255.255.255.0
no shut
exit
int g0/0.2
encapsulation dot1Q 20
ip address 192.168.2.1 255.255.255.0
no shut
exit
int g0/0.3
encapsulation dot1Q 30
ip address 192.168.3.1 255.255.255.0
no shut
exit
router rip
version 2
network 192.168.1.0
network 192.168.2.0
network 192.168.3.0
end
copy run start
If you want to do testing VLan configuration in packet tracer, please click here to download VLan.pkt.