You are on page 1of 4

Student name : ………………………

Student no. : ………………………

CPIS 370
Lab (6)

Objectives
 Design and build a LAN network with 2 PCs and 1 switch using a Cisco Packet tracer program
 Create a basic switch configuration and verify it.
 Create two VLANs, name them and assign member ports to them.
 Verify connectivity between a network LAN .
The requirements to make the network shown in the figure above are:

 1 Switch
 2 PCs
 NIC for each PC
 Straight Cables

Step 1 : build LAN and Configure the switch

1. Access and command mode, Start the Basic Switch Configuration lab Configure the hostname
passwords , and management LAN " VLAN 1" .

Switch1>enable
Switch1#
Switch1#show running-config
Switch1#configure terminal
Switch1(config)#hostname Switch1
Switch1(config)#exit
---------------------------------------
Switch1(config)#line con 0
Switch1(config-line)#password cisco
Switch1(config-line)#login
Switch1(config-line)#line vty 0 15
Switch1(config-line)#password cisco
Switch1(config-line)#login
Switch1(config-line)#exit

Switch1(config)#interface VLAN 1
Switch1(config-if)#ip address 192.168.1.2 255.255.255.0
Switch1(config-if)#exit
Student name : ………………………
Student no. : ………………………

Step 2 : Configure the hosts attached to the switch

Configure the hosts to use the same subnet for the address, mask, and default gateway as on the

switch.

Host B

Host A IP Address : 192.186.1.4

IP Address : 192.186.1.3 Subnet :255.255.255.0

Subnet :255.255.255.0 Gateway :192.186.1.1

Gateway :192.186.1

Step 3 : Verify connectivity

1. ping the switch from the host. Write the command ?

_________________________________________________

2. Was the ping successful?

__________________________________________________

Step 4: Display the VLAN interface information

On Switch1 , type the command show vlan at the Privileged EXEC prompt as follows:

Switch1#show vlan

1. Which ports belong to the default VLAN?

________________________________________

2. How many VLANs are set up by default on the switch?

________________________________________
Student name : ………………………
Student no. : ………………………

Step 5: Create and name two VLANs

Enter the following commands to create and name two VLANs:

Switch1#vlan database
Switch1(vlan)#vlan 2 name VLAN2
Switch1(vlan)#vlan 3 name VLAN3
Switch1(vlan)#exit

Step 6: Display the VLAN interface information

. On Switch1, type the command show vlan at the Privileged EXEC prompt as follows:
Switch_A#show vlan

Step 7: Assign ports to VLAN 2

Assigning ports to VLANs must be done from the interface mode. Enter the following commands to

1. Add ports 4, 5 and 6 to VLAN 2.

Switch1#configure terminal
Switch1(config)#interface fastethernet 0/4
Switch1(config-if)#switchport mode access
Switch1(config-if)#switchport access vlan 2

Switch1(config-if)#interface fastethernet 0/5


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

Switch1(config-if)#interface fastethernet 0/6


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

Switch1(config-if)#end

Step 8 : Assign ports to VLAN 3

Assigning ports to VLANs must be done from the interface mode. Enter the following commands :

1. Add port 2 to VLAN 3:

Switch1#configure terminal
Switch1(config)#interface fastethernet 0/2
Switch1(config-if)#switchport mode access
Switch1(config-if)#switchport access vlan 2

Switch1(config-if)#end
Student name : ………………………
Student no. : ………………………

Step9 : Display the VLAN interface information

On Switch1 , type the command show VLAN at the Privileged EXEC prompt as follows:

Switch1#show vlan

1. Witch ports are assigned to VLAN 2 ?

________________________________________________

2. Is port 2 assigned to VLAN 3?

________________________________________________

Step 10 : Verify connectivity

: Use ping command on from the PC to the other

Host A # Ping 192.186.1.2

Host A # Ping 192.186.1.4

? What is the result .1

________________________________________________

You might also like