CCNA 200 - 301 - Lesson 56: Understanding Default VLAN and Configuring VLANs

Опубликовано: 05 Октябрь 2024
на канале: Network Bulls
772
4

Section - 12: Understand, Configure and Verify VLANs
Lesson 56: Understanding Default VLAN and Configuring VLANs

In this video, we will study quite an important concept that is - How to use CLI of Cisco Switch.

Follow the steps given below:
Switch CLI configuration:
Step 1: First, select a switch (2950-24 Switch1) and then select 4 computers (PC-PTPC0, PC-PTPC1, PC-PTPC2, & PC-PTPC3).
Step 2: Press and hold the ‘Ctrl’ key and select the connections option and then connect all the 4 computers to the switch in one go.
Step 3: Click on the switch then you will get multiple options in the newly opened window. Select CLI option.
Step 3: Type ‘enable’ command to go into the next mode for further configuration and troubleshooting.
Step 4: Type ‘configuration terminal’ command to go into global configuration mode to perform sub-configurations.
Step 5: Type ‘hostname’ command to define hostname on switch.
Step 6: Type ‘enable password’ command to set a password.
Step 7: Type ‘show vlan brief’ command to see the VLAN on the switch.

Computer configuration:
Step 1: Click on the computer and go to the desktop then IP configuration.
Step 2: Input the IP-Address and press tab key and the subnet mask will auto-appear. Do the same with all 4 computers to assign them an IP-Address.
Step 3: Change the connection from real-time to stimulation and send a packet from computer0 (PC-PTPC0) to computer1 (PC-PTPC1) so the computer0 will generate an ARP packet.
So, whenever computer0 will send a broadcast packet to the switch, the switch will send to all the computers but the reply will be given from that computer to whom the ARP belongs i.e. computer1.
Step 4: Check the ARP table of the computer by clicking on the computer and go to the command prompt option and type ‘arp-a’ and see the computer has now the MAC address of the sender/receiver.
Note: Whenever a device wants to communicate with another device we always require a MAC address of that device with which we are communicating. To resolve a destination MAC address with the help of destination IP address there is a process which is called ARP, it stands for Address Resolution Protocol.

VLANs Configurations:
Step 1: Get back to the CLI of switch where, to create a VLAN we need 2 broadcast domains. So, divide those computers into 2 broadcast domains i.e. (Domain1 = Computer0 & Coputer1 = VLAN1) (Domain2 = Computer2 & Computer3 = VLAN10).
Step 2: In CLI, type command vlan and then assign the number and name to the VLAN and then type the command vlan brief to check the available VLANs and to which port they are allocated.
Step 3: Type ‘configuration terminal’ command, then type ‘interface FastEthernet 0/1’ command, then type ‘switchport access vlan 10’ command to configure a port into the VLAN. Follow the same process to configure the port 0/4 into the VLAN.
Step 4: Change the connection from real-time to stimulation and send a packet from computer0 (PC-PTPC2) to computer1 (PC-PTPC3).
So, when you forward the packet, the switch will not send the green packet to computer0 and computer1, instead, it will send the same only to computer3 because computer2 and computer3 belong to the different VLAN (Domain2).

These are some other commands used in relation to VLANs:
Write: This command is used for saving the configurations.
Show flash: Used to check where the VLAN information has been saved. By using this command you will be able to see your file in the form of ‘vlan.dat’. All VLAN information is always stored in the vlan.dat file.
In this video, we have understood what VLAN is, why we use VLAN, how to create a VLAN, and how to modify VLAN.
If you have any doubt just ask us in the comment section.
Happy Learning :)