lab 14 - spanning tree

10
CCNA Lab Lab 14 SPANNING TREE PROTOCOL Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) [email protected] Page 1 SPANNING-TREE PROTOCOL 1. Kết ni thiết bnhư hình. 2. Cu hình tên cho các thiết bSwitch. 3. Đặt địa chIP PC0 và PC1 cùng đường mng vi địa chIP là: 192.168.1.2/24 và 192.168.1.3/24. Cu hình chc năng portfast trên các cng fa0/20 ca Switch1 và Switch2 4. Kim tra Spanning Tree trên các Switch, đọc hiu các thông tin trên các Switch. 5. Thc hin cu hình Priority là 4096 trên Switch2 để Switch2 trthành Root Bridge. Kim tra li thông tin Spanning-Tree. 6. Thc hin shutdown cng Fa0/5 trên Switch1 trong khi đó tiếp tc ping tPC0 đến PC1. Kim tra thi gian mt gói. 7. Thc hin thay đổi PVST+ sang PVRST+ trên tt ccác Switch. Kim tra li thông tin Spanning- Tree. 8. Lưu cu hình.

Upload: nobis812

Post on 21-Oct-2015

37 views

Category:

Documents


2 download

TRANSCRIPT

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 1

SPANNING-TREE PROTOCOL

1. Kết nối thiết bị như hình.

2. Cấu hình tên cho các thiết bị Switch.

3. Đặt địa chỉ IP PC0 và PC1 cùng đường mạng với địa chỉ IP là: 192.168.1.2/24 và 192.168.1.3/24.

Cấu hình chức năng portfast trên các cổng fa0/20 của Switch1 và Switch2

4. Kiểm tra Spanning Tree trên các Switch, đọc hiểu các thông tin trên các Switch.

5. Thực hiện cấu hình Priority là 4096 trên Switch2 để Switch2 trở thành Root Bridge. Kiểm tra lại

thông tin Spanning-Tree.

6. Thực hiện shutdown cổng Fa0/5 trên Switch1 trong khi đó tiếp tục ping từ PC0 đến PC1. Kiểm

tra thời gian mất gói.

7. Thực hiện thay đổi PVST+ sang PVRST+ trên tất cả các Switch. Kiểm tra lại thông tin Spanning-

Tree.

8. Lưu cấu hình.

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 2

Hướng dẫn:

1. Kết nối thiết bị như hình.

2. Cấu hình tên cho các thiết bị Switch.

Switch(config)#hostname Switch0

Switch0(config)#

Switch(config)#hostname Switch1

Switch1(config)#

Switch(config)#hostname Switch2

Switch2(config)#

Switch(config)#hostname Switch3

Switch3(config)#

3. Đặt địa chỉ IP PC0 và PC1 cùng đường mạng với địa chỉ IP là: 192.168.1.2/24 và 192.168.1.3/24.

Cấu hình chức năng portfast trên các cổng fa0/20 của Switch1 và Switch2.

- Đặt địa chỉ IP cho PC0 và PC1

PC>ipconfig /all

Physical Address................: 00E0.A336.9554

IP Address......................: 192.168.1.2

Subnet Mask.....................: 255.255.255.0

Default Gateway.................: 192.168.1.1

DNS Servers.....................: 0.0.0.0

PC>ipconfig /all

Physical Address................: 0001.9764.E731

IP Address......................: 192.168.1.3

Subnet Mask.....................: 255.255.255.0

Default Gateway.................: 192.168.1.1

DNS Servers.....................: 0.0.0.0

PC>ping 192.168.1.3

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 3

Pinging 192.168.1.3 with 32 bytes of data:

Reply from 192.168.1.3: bytes=32 time=125ms TTL=128

Reply from 192.168.1.3: bytes=32 time=125ms TTL=128

Reply from 192.168.1.3: bytes=32 time=110ms TTL=128

Reply from 192.168.1.3: bytes=32 time=77ms TTL=128

Ping statistics for 192.168.1.3:

Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

Approximate round trip times in milli-seconds:

Minimum = 77ms, Maximum = 125ms, Average = 109ms

- Cấu hình chức năng PortFast:

Switch1(config)#interface fastEthernet 0/20

Switch1(config-if)#spanning-tree portfast

%Warning: portfast should only be enabled on ports connected to a single

host. Connecting hubs, concentrators, switches, bridges, etc... to this

interface when portfast is enabled, can cause temporary bridging loops.

Use with CAUTION

%Portfast has been configured on FastEthernet0/20 but will only

have effect when the interface is in a non-trunking mode.

Switch1(config-if)#no shut

Switch2(config)#interface fastEthernet 0/20

Switch2(config-if)#spanning-tree portfast

%Warning: portfast should only be enabled on ports connected to a single

host. Connecting hubs, concentrators, switches, bridges, etc... to this

interface when portfast is enabled, can cause temporary bridging loops.

Use with CAUTION

%Portfast has been configured on FastEthernet0/20 but will only

have effect when the interface is in a non-trunking mode.

Switch2(config-if)#no shut

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 4

4. Kiểm tra Spanning Tree trên các Switch, đọc hiểu các thông tin trên các Switch.

Switch0#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 32769

Address 0007.EC7A.6057

This bridge is the root

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

Address 0007.EC7A.6057

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/1 Desg FWD 19 128.1 P2p

Fa0/2 Desg FWD 19 128.2 P2p

Switch1#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 32769

Address 0007.EC7A.6057

Cost 19

Port 3(FastEthernet0/3)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 5

Address 00E0.B009.BEE8

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/3 Root FWD 19 128.3 P2p

Fa0/5 Altn BLK 19 128.5 P2p

Fa0/7 Desg FWD 19 128.7 P2p

Fa0/9 Desg FWD 19 128.9 P2p

Fa0/20 Desg FWD 19 128.20 P2p

Switch2#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 32769

Address 0007.EC7A.6057

Cost 19

Port 4(FastEthernet0/4)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

Address 0060.4799.9468

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/4 Root FWD 19 128.4 P2p

Fa0/6 Desg FWD 19 128.6 P2p

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 6

Fa0/20 Desg FWD 19 128.20 P2p

Switch3#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 32769

Address 0007.EC7A.6057

Cost 19

Port 8(FastEthernet0/8)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

Address 00E0.A3E4.2AA9

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/8 Root FWD 19 128.8 P2p

Fa0/10 Altn BLK 19 128.10 P2p

5. Thực hiện cấu hình Priority là 4096 trên Switch2 để Switch2 trở thành Root Bridge. Kiểm tra lại

thông tin Spanning-Tree.

Switch2(config)#spanning-tree vlan 1 priority 4096

Switch2#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 4097

Address 0060.4799.9468

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 7

This bridge is the root

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 4097 (priority 4096 sys-id-ext 1)

Address 0060.4799.9468

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/4 Desg FWD 19 128.4 P2p

Fa0/6 Desg FWD 19 128.6 P2p

Fa0/20 Desg FWD 19 128.20 P2p

6. Thực hiện shutdown cổng Fa0/5 trên Switch1 trong khi đó tiếp tục ping từ PC0 đến PC1. Kiểm

tra thời gian mất gói.

Switch1(config)#interface fastEthernet 0/5

Switch1(config-if)#shutdown

%LINK-5-CHANGED: Interface FastEthernet0/5, changed state to administratively

down

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/5, changed state

to down

PC>ping -t 192.168.1.3

Pinging 192.168.1.3 with 32 bytes of data:

Reply from 192.168.1.3: bytes=32 time=109ms TTL=128

Reply from 192.168.1.3: bytes=32 time=94ms TTL=128

Reply from 192.168.1.3: bytes=32 time=94ms TTL=128

Reply from 192.168.1.3: bytes=32 time=94ms TTL=128

Reply from 192.168.1.3: bytes=32 time=94ms TTL=128

Request timed out.

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 8

Request timed out.

Request timed out.

Request timed out.

Request timed out.

Reply from 192.168.1.3: bytes=32 time=125ms TTL=128

Reply from 192.168.1.3: bytes=32 time=82ms TTL=128

Reply from 192.168.1.3: bytes=32 time=110ms TTL=128

Ping statistics for 192.168.1.3:

Packets: Sent = 42, Received = 37, Lost = 5 (12% loss),

Approximate round trip times in milli-seconds:

Minimum = 62ms, Maximum = 140ms, Average = 102ms

Switch1#show spanning-tree

VLAN0001

Spanning tree enabled protocol ieee

Root ID Priority 4097

Address 0060.4799.9468

Cost 19

Port 3(FastEthernet0/3)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

Address 00E0.B009.BEE8

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/3 Root FWD 19 128.3 P2p

Fa0/7 Desg FWD 19 128.7 P2p

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 9

Fa0/9 Desg FWD 19 128.9 P2p

Fa0/20 Desg FWD 19 128.20 P2p

7. Thực hiện thay đổi PVST+ sang PVRST+ trên tất cả các Switch. Kiểm tra lại thông tin Spanning-

Tree.

Switch0(config)#spanning-tree mode rapid-pvst

Switch1(config)#spanning-tree mode rapid-pvst

Switch2(config)#spanning-tree mode rapid-pvst

Switch3(config)#spanning-tree mode rapid-pvst

Kiểm tra thông tin Spanning-Tree

Switch1#show spanning-tree

VLAN0001

Spanning tree enabled protocol rstp

Root ID Priority 4097

Address 0060.4799.9468

Cost 19

Port 3(FastEthernet0/3)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)

Address 00E0.B009.BEE8

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Aging Time 20

Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/3 Root FWD 19 128.3 P2p

Fa0/7 Desg FWD 19 128.7 P2p

Fa0/9 Desg FWD 19 128.9 P2p

Fa0/20 Desg FWD 19 128.20 P2p

CCNA Lab Lab 14 – SPANNING TREE PROTOCOL

Instructor: Tran Dang Minh Khoa CCIE wr ( R&S) – [email protected] Page 10

8. Lưu cấu hình.

Switch0#wr

Building configuration...

[OK]

Switch1#wr

Building configuration...

[OK]

Switch2#wr

Building configuration...

[OK]

Switch3#wr

Building configuration...

[OK]