0% found this document useful (0 votes)
34 views

Lab 4

resytfgfd g

Uploaded by

Choudhary Behram
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views

Lab 4

resytfgfd g

Uploaded by

Choudhary Behram
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

CONFIGURATION OF VLAN

TRUNKING
Lab-04

Computer Networks
COSC-3201

Lab Instructor:
Mr. Muhammad Tariq Ali
Student Name

Student Roll #

Department

Year/Section
1. OBJECTIVES
Perform an initial configuration of a Cisco Catalyst 2960 switch and PCs.
Configuring VLAN Trunking in Cisco Packet tracer

Lab Task 1:

Virtual LANS:

A virtual LAN is any broadcast domain that is partitioned and isolated in a computer network at the
data link layer.

Step 1:

Configure following topology in Cisco Packet tracer


Step 2: Assign IP addresses to Router and all PCs.

Step 3: Create VLAN 2 (Name: CS) and VLAN 3 (Name: IT ) on both switches:
Switch1 #config terminal
Switch1 (config)#vlan 2
Switch1 (config-vlan)#name CS
Switch1 (config-vlan)#vlan 3
Switch1 (config-vlan)#name IT

Switch2 #config terminal


Switch2 (config)#vlan 2
Switch2 (config-vlan)#name CS
Switch2 (config-vlan)#vlan 3
Switch2 (config-vlan)#name IT

Step 4: Assign Interfaces to VLANs.


Switch1>enable
Switch1#config terminal

Switch1 (config)#int fa0/2


Switch1 (config-if)#switchport mode access
Switch1 (config-if)#switchport access vlan 2

Switch1 (config-if)#int fa0/3


Switch1 (config-if)#switchport mode access
Switch1 (config-if)#switchport access vlan 3

Switch2 >enable
Switch2 #config terminal
Switch2 (config)#int fa0/4
Switch2 (config-if)#switchport mode access
Switch2 (config-if)#switchport access vlan 2

Switch2 (config-if)#int fa0/2


Switch2 (config-if)#switchport mode access
Switch2 (config-if)#switchport access vlan 3

Lab Task 2: Configure an 802.1Q Trunk Between the Switches.


In task 2, you will configure interface F0/1 on switch 1 and interface 0/1 on switch 2 as a trunk.

Trunk ports are used when another switch is connected to this interface, and this link is carrying
multiple VLANs (trunk link).

Note: By default, all VLANs are allowed on a trunk. The switchport trunk command
allows you to control what VLANs have access to the trunk. For this lab, keep the
default settings which allows all VLANs to traverse F0/1.

Step 1: Manually configure trunk interface F0/1.


The switchport mode trunk command is used to manually configure a port as a trunk.
This command should be issued on both ends of the link.
a. Change the switchport mode on interface F0/1 to force trunking. Make sure to do
this on both switches.
Switch1(config)# interface f0/1
Switch1(config-if)# switchport mode trunk
b. Issue the show interfaces trunk command to view the trunk mode.
c. Switch2(config)# interface f0/1
Switch2(config-if)# switchport mode trunk

Switch2# show interfaces trunk

Lab Task 5: Delete the VLAN Database


In task 5, you will delete the VLAN Database from the switch. It is necessary to do this
when initializing a switch back to its default settings.
Step 1: Determine if the VLAN database exists.
Issue the show flash command to determine if a vlan.dat file exists in flash.
S1# show flash

Note: If there is a vlan.dat file located in flash, then the VLAN database does not
contain its default settings.
Step 2: Delete the VLAN database.
a. Issue the delete vlan.dat command to delete the vlan.dat file from flash and reset
the VLAN database back to its default settings. You will be prompted twice to confirm
that you want to delete the vlan.dat file. Press Enter both times.
S1# delete vlan.dat
Delete filename [vlan.dat]?
Delete flash:/vlan.dat? [confirm] S1#
b. Issue the show flash command to verify that the vlan.dat file has been deleted
S1# show flash

You might also like