Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 10

go

SWITCH BASIC









1. Truy cp t my tnh n Switch thng qua cng console.

2. ng nhp vo: userexec mode, privilege mode, config mode.

3. Cu hnh tn Switch: Switch_tenhocvien

4. Hin th ng h, cu hnh li ng h cho ng vi thi gian hin ti.

5. Cu hnh li b m lnh cha 15 lnh gn nht.

6. Cu hnh cc password v m ho:

a. Password enable: cisco
b. Enable Secret: ciscosecret
c. Console: ciscoconsole
d. Telnet: ciscotelnet

7. Cu hnh Banner motd l: Day la router do ten_hoc_vien cau hinh, khong phan su mien thao tac!

8. Cu hnh interface Vlan 1 c a ch IP l 192.168.1.10/24

9. Cu hnh default gateway cho switch vi a ch IP l 192.168.1.1/24

10. Cu hnh cho cc cng t cng 1 n cng 5 hot ng, cc cng cn li trng thi shutdown.
11. Thc hin copy cu hnh lm. Dng cc lnh show running-config, show startup-config, show
version, show ip interface brief kim tra cu hnh.

12. Kim tra bng MAC bng lnh show mac-address-table.

13. Thc hin thao tc Crack password vi thit b.











Hng dn:

1. Truy cp t my tnh n Switch thng qua cng console.

2. ng nhp vo: userexec mode, privilege mode, config mode.

Nhn Enter lm xut hin du nhc lnh (command prompt). Du nhc lnh ny bao gm 2 thnh phn: chui
Switch l hostname ca Router1 v k t > cho bit ta ang user mode.

Switch>

G lnh enable vo privileged mode v du > c thay bng du #.

Switch>enable

tr v user mode, ta g disable. T user mode, g tip logout hoc exit thot khi Switch.

Switch#disable

G lnh config terminal vo mode Config mode (Mode chnh cu hnh thit b Switch hoc router)

Switch#config terminal

Sau khi g lnh Config terminal du nhc ca Switch s c chuyn thnh Switch(config)#
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#

3. Cu hnh tn Switch: Switch_tenhocvien

cu hnh tn cho thit b l Switch_tenhocvien ta g lnh
Switch(config)#hostname Switch_ten_hoc_vien

Sau khi g lnh trn tn ca thit b s c i
Switch_ten_hoc_vien(config)#

4. Hin th ng h, cu hnh li ng h cho ng vi thi gian hin ti.

Switch_ten_hoc_vien#show clock

*0:1:58.47 UTC Mon Mar 1 1993
Switch_ten_hoc_vien#clock set 09:24:00 24 feb 2011
Switch_ten_hoc_vien#show clock

*9:24:3.375 UTC Thu Feb 24 2011

5. Cu hnh li b m lnh cha 15 lnh gn nht.

Switch_ten_hoc_vien#terminal history size 15

6. Cu hnh cc password v m ho:

a. Password enable: cisco

t password cho thit b ta g lnh

Switch_ten_hoc_vien(config)#enable password cisco

Sau khi g lnh trn ta thot ra khi mode Config v vo li

Switch>enable
Password:

y ta nhp Password cu hnh trn tip tc vo privilege mode

b. Enable Secret: cisco

Ta tin hnh b password t nhng khng m ha trn bng lnh

Switch ten hoc vien(config)# no enable password cisco

m ha cc password ta g lnh

Switch_ten_hoc_vien(config)#enable secret cisco

Lnh ny m ha tt c cc password s nhp vo Switch ( kim tra cc bn c th
g lnh

Switch ten hoc vien# show running-config

!
hostname Switch
!
enable password cisco

(t password nhng cha m ha)

hostname Switch
!
enable secret 5 $1$mERr$hx5rVt7rPNoS4wqbXKX7m0
!

(t password v c m ha)

c. Console: ciscoconsole
Switch_ten_hoc_vien(config)#line console 0
Switch_ten_hoc_vien(config-line)#password ciscoconsole
Switch_ten_hoc_vien(config-line)#login

d. Telnet: ciscotelnet





Switch_ten_hoc_vien(config)#line vty 0 4
Switch_ten_hoc_vien(config-line)#password ciscotelnet
Switch_ten_hoc_vien(config-line)#login

e. M ho

Switch_ten_hoc_vien(config)#service password-encryption

7. Cu hnh Banner motd l: Day la Switch do ten_hoc_vien cau hinh, khong phan su mien thao tac!

Switch_ten_hoc_vien(config)#banner motd ^Day la Switch do ten_hoc_vien cau
hinh, khong phan su mien thao tac^

8. Cu hnh interface Vlan 1 c a ch IP l 192.168.1.10/24

Switch_ten_hoc_vien(config)#interface vlan 1
Switch_ten_hoc_vien(config-if)#ip address 192.168.1.10 255.255.255.0
Switch_ten_hoc_vien(config-if)#no shutdown

%LINK-5-CHANGED: Interface Vlan1, changed state to up

9. Cu hnh default gateway cho switch vi a ch IP l 192.168.1.1/24

Switch_ten_hoc_vien(config)#ip default-gateway 192.168.1.1

10. Cu hnh cho cc cng t cng 1 n cng 5 hot ng, cc cng cn li trng thi shutdown.
Switch_ten_hoc_vien(config)#interface range fastEthernet 0/1 - 5
Switch_ten_hoc_vien(config-if-range)#no shutdown
Switch_ten_hoc_vien(config-if-range)#exit
Switch_ten_hoc_vien(config)#interface range fastEthernet 0/6-24
Switch_ten_hoc_vien(config-if-range)#shutdown
11. Thc hin copy cu hnh lm. Dng cc lnh show running-config, show startup-config, show
version, show ip interface brief kim tra cu hnh.

Switch_ten_hoc_vien#wr
Building configuration...
[OK]



Switch_ten_hoc_vien#show running-config

Building configuration...






Current configuration : 1518 bytes
!

version 12.2
no service timestamps log datetime msec no
service timestamps debug datetime msec
service password-encryption

!
hostname Switch_ten_hoc_vien
!

enable secret 5 $1$mERr$wZMkJsj2RVk4hay2C4T32.

enable password 7 0822455D0A16

()



Switch_ten_hoc_vien#show startup-config

Using 1518 bytes

!

version 12.2
no service timestamps log datetime msec no
service timestamps debug datetime msec
service password-encryption

!
hostname Switch_ten_hoc_vien
!

enable secret 5 $1$mERr$wZMkJsj2RVk4hay2C4T32.

enable password 7 0822455D0A16

()



Switch_ten_hoc_vien#show version

Cisco IOS Software, C2960 Software (C2960-LANBASE-M), Version 12.2(25)FX,
RELEASE SOFTWARE (fc1)






Copyright (c) 1986-2005 by Cisco Systems, Inc.

Compiled Wed 12-Oct-05 22:05 by pt_team

ROM: C2960 Boot Loader (C2960-HBOOT-M) Version 12.2(25r)FX, RELEASE SOFTWARE
(fc4)

System returned to ROM by power-on

Cisco WS-C2960-24TT (RC32300) processor (revision C0) with 21039K bytes of
memory.

24 FastEthernet/IEEE 802.3 interface(s)

2 Gigabit Ethernet/IEEE 802.3 interface(s)

63488K bytes of flash-simulated non-volatile configuration memory.

Base ethernet MAC Address : 0001.C734.877A

Motherboard assembly number : 73-9832-06

Power supply part number : 341-0097-02

Motherboard serial number : FOC103248MJ

Power supply serial number : DCA102133JA

Model revision number : B0

Motherboard revision number : C0

Model number : WS-C2960-24TT

System serial number : FOC1033Z1EY

Top Assembly Part Number : 800-26671-02

Top Assembly Revision Number : B0

Version ID : V02

CLEI Code Number : COM3K00BRA

Hardware Board Revision Number : 0x01

Switch Ports Model SW Version SW Image



1 26 WS-C2960-24TT 12.2 C2960-LANBASE-M

Configuration register is 0xF



Switch_ten_hoc_vien#show ip interface brief

Interface IP-Address OK? Method Status Protocol






FastEthernet0/1 unassigned YES manual down down



FastEthernet0/2 unassigned YES manual down down



FastEthernet0/3 unassigned YES manual down down



FastEthernet0/4 unassigned YES manual down down



FastEthernet0/5 unassigned YES manual down down



FastEthernet0/6 unassigned YES manual administratively down down



FastEthernet0/7 unassigned YES manual administratively down down



FastEthernet0/8 unassigned YES manual administratively down down



FastEthernet0/9 unassigned YES manual administratively down down



FastEthernet0/10 unassigned YES manual administratively down down

()

12. Kim tra bng MAC bng lnh show mac-address-table.

Switch_ten_hoc_vien#show mac-address-table

Mac Address Table



Vlan Mac Address Type Ports



All 0012.7f7a.0f80 STATIC CPU

All 0100.0ccc.cccc STATIC CPU

All 0100.0ccc.cccd STATIC CPU

All 0100.0cdd.dddd STATIC CPU





1 0000.746e.5f33 DYNAMIC Fa0/24

1 0000.aac6.8682 DYNAMIC Fa0/23

1 0002.b3a9.1cf1 DYNAMIC Fa0/24

1 000b.db53.be0c DYNAMIC Fa0/24

1 000f.24bd.2e97 DYNAMIC Fa0/23

1 000f.24c3.8298 DYNAMIC Fa0/24

1 001a.a0c2.4e7e DYNAMIC Fa0/24

1 001a.a0c2.72a6 DYNAMIC Fa0/3

1 001b.38c4.4d0d DYNAMIC Fa0/24

1 001c.2333.b8f4 DYNAMIC Fa0/23

1 001e.4ff7.c149 DYNAMIC Fa0/10

1 0021.9b3e.c6a2 DYNAMIC Fa0/4

1 0021.9bfd.d705 DYNAMIC Fa0/21

1 0023.5d75.d6c3 DYNAMIC Fa0/23

1 0024.e8a6.c6bc DYNAMIC Fa0/19

1 0025.b3f1.ef24 DYNAMIC Fa0/23

1 00b0.1933.83ee DYNAMIC Fa0/23

1 18a9.05bc.aadc DYNAMIC Fa0/24

1 6c62.6d5c.4f8c DYNAMIC Fa0/23

1 6c62.6d5c.5016 DYNAMIC Fa0/23

Total Mac Addresses for this criterion: 24

13. Thc hin thao tc Crack password vi thit b.

- Tt ngun thit b Switch, i 5 pht.

- Bt ngun thit b ng thi bm nt gi mode trn Switch n khi no trn mn hnh
Console hin th dng ch

Switch:

- G 2 lnh di thit lp cc thng s cn thit cho switch h tr nhn flash

Switch: flash_init

Switch: load_helper

- Kim tra file cu hnh startup-config c cha trong Flash c tn config.text





Switch: dir flash:

Directory of flash:/

2 -rwx 1277 <date> config.text

4 -rwx 584 <date> vlan.dat

5 -rw- 4414921 <no date> c2960-lanbase-mz.122-25.FX.bin

463 -rwx 24 <date> private-config.text

464 -rwx 1048 <date> multiple-fs

19619328 bytes available (12894720 bytes used)

- i tn file cu hnh

Switch: rename flash: config.text flash:config.ccna

- Kim tra vic thay i thnh cng

Switch: dir flash:

Directory of flash:/

2 -rwx 1277 <date> config.ccna

4 -rwx 584 <date> vlan.dat

5 -rw- 4414921 <no date> c2960-lanbase-mz.122-25.FX.bin

463 -rwx 24 <date> private-config.text

464 -rwx 1048 <date> multiple-fs

- Thc hin Boot Switch:

Switch: boot

- Sau khi thit b Boot xong, thc hin vic i tn cho file config.ccna tr li thnh config.text

Switch> enable
Switch# rename flash:config.ccna flash:config.text
Switch# dir flash:

Directory of flash:/

2 -rwx 1277 <date> config.text

4 -rwx 584 <date> vlan.dat

5 -rw- 4414921 <no date> c2960-lanbase-mz.122-25.FX.bin

463 -rwx 24 <date> private-config.text






464 -rwx 1048 <date> multiple-fs

- Thc hin copy thng tin cu hnh t config.text ra running-config

Switch#copy flash:config.text running-config

- Thc hin thay i cc password cn thit (trng hp ny l enable secret)

Switch_ten_hoc_vien(config)#enable secret cisco123

- Thc hin lu cu hnh va chnh sa.

Switch_ten_hoc_vien#copy running-config startup-config

You might also like