Name: _________________ Student I.
D: _________________
6 Lab 06- Basic configuration and operation of Network Switch
6.1 Objective
Running basic Cisco switch configuration commands and understand basic operation.
6.2 Theory
Network Switch and Operation of Ethernet Switches
In a network, a switch is a device that channels incoming data from any of multiple input ports
to the specific output port that will take it toward its intended destination. Networks exist to move
data between computers. To perform that task, the network software organizes the data being moved
into Ethernet frames. Frames travel over Ethernet networks, and the data field of a frame is used to carry
data between computers.
6.2 Basic Cisco switch configuration commands
To configure a cisco switch with basic configuration
1) Accessing Console of the Switch/Router
2) Modes of CLI
3) Set Hostname and Configure Console Password
4) Set Privilege level password
5) Set User Authentication in Switch
6) Set Telnet password
7) Enable the Device to Establish Telnet/SSH Session
8) Configuring SSH
1) Accessing Console of the Switch/Router
Figure 6-1: Accessing console of the switch/Router
34
RJ-45 to DB-9 adapter is used on the PC (COM port) to the device console Port through a roll-over cable.
Hyper Terminal is used to access the Command Line Interface (CLI) of the Device. (Start --Menu—
Programs—Accessories—Communications--Hyper Terminal)
Figure 6-2: Command Line Interface
Switch Console
Modes of CLI:
User-exec mode Switch>
Privilege mode Switch#
Global Configuration mode Switch(config)#
Switch in different modes:
Switch> enable
Switch# config terminal
Switch(config)#
Note: To return to the previous mode use “Exit” command in the current mode.
35
Set Hostname and Configure Console Password:
Switch(config)# hostname CISCO
CISCO(config)#line console 0
CISCO(config-line)#password cisco123
CISCO(config-line)#login
Set Privilege level password:
!!! Clear Text Password not encrypted (less priority)
CISCO(config)#enable password ccna123
!!! Encrypted password (more Priority)
CISCO(config)#enable secret cttc123
Verify the Password
CISCO(config)#exit
CISCO#exit CISCO con0 is now available
Press RETURN to get started.
User Access Verification
!!! TYPE HERE LINE CONSOLE Password
Password: CISCO>enable!!! TYPE HERE Privilege Level Password
Password:
Figure 6-3: Verify the password
36
Set User Authentication in Switch
CISCO#config terminal
CISCO (config)#line console 0
CISCO(config-line)# login local
CISCO(config-line)#exit
CISCO(config)#username cttc password ccna123
Figure 6-4: Verify the Authentication
CISCO(config)#exit
CISCO# exit
Set Telnet password:
CISCO(config)#line vty 0 15
CISCO(config-line)#password cisco
CISCO(config-line)#login
CISCO(config-line)#exit
Enable the Device to Establish Telnet/SSH Session:
CISCO(config)#interface vlan 1
CISCO(config-if)#ip address [Link] [Link]
CISCO(config-if)#no shutdown
37
Note: VLAN 1 IP address is used to establish the telnet session. Go to command prompt and use telnet
command to make a telnet session with the device.
C:\>telnet [Link]
Figure 6-5: Enable devices to Establish Telnet
38