1 / 29

交换技术 STP

Module 5-5. 交换技术 STP. 冗余的拓扑. 冗余的链路排除了单点故障的问题 . 冗余的链路导致广播风暴 , 重复帧 , 以及 MAC 地址表的不稳定。. 广播帧. Station D sends a broadcast frame. Broadcast frames are flooded to all ports except the originating port. 广播风暴. 主机 X 发送一个广播帧 . 交换机继续不断的传送广播帧. 重复帧. 主机 X 发送单播帧到路由器 Y.

Télécharger la présentation

交换技术 STP

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Module 5-5 交换技术 STP

  2. 冗余的拓扑 • 冗余的链路排除了单点故障的问题. • 冗余的链路导致广播风暴, 重复帧,以及MAC地址表的不稳定。

  3. 广播帧 • Station D sends a broadcast frame. • Broadcast frames are flooded to all ports except the originating port.

  4. 广播风暴 • 主机 X 发送一个广播帧. • 交换机继续不断的传送广播帧.

  5. 重复帧 • 主机X发送单播帧到路由器Y. • 如果交换机的MAC地址表中没有路由器Y的MAC地址. • 路由器将会收到两个相同的数据帧.

  6. MAC地址表的不稳定 • 主机X发送单播帧到路由器Y. • 路由器Y的MAC地址没有被交换机学习. • 交换机A 和 B从端口1中学习到主机X的MAC地址. • 但是发往路由器Y的数据帧被泛洪. • 交换机A和B错误的从端口2再次学习了主机X的MAC地址.

  7. 利用 STP 解决环路 • 通过将个别端口设置为blocking状态可以为网络提供一个无环的网络 • 它公布在IEEE 802.1D • Cisco 执行更强的PVST+

  8. Spanning-Tree 操作 • 每个广播域一个根桥. • 每个非根桥上一个根端口. • 每个网段上一个指定端口. • 为指派的端口不使用.

  9. STP 根桥的选举 • BPDU (default = sent every 2 seconds) • Root bridge = bridge with the lowest bridge ID • Bridge ID = Bridge Priority MAC Address

  10. Spanning-Tree 端口状态 Spanning tree transits each port through several different states:

  11. Uplinkfast / Backbonefast SwitchX(config)# spanning-tree uplinkfast • 用来在本地交换机上检测链路失效,并且能快速修复链路失效 ,一般只用于接入层交换机 SwitchX(config)# spanning-tree backbonefast • 用来在远端交换机上检测链路失效,一般可用于所有交换机

  12. PortFast PortFast 是配置在 access 上,而不是 trunk 端口.

  13. Configuring and Verifying PortFast SwitchX(config-if)# spanning-tree portfast • Configures PortFast on an interface OR SwitchX(config)# spanning-tree portfast default • Enables PortFast on all non-trunking interfaces SwitchX# show running-config interface interface • Verifies that PortFast has been configured on an interface

  14. BPDU护卫 / 过滤器 SwitchX(config-if)# spanning-tree bpduguard enable/disable • 在接入层交换机实用,允许接收BPDU SwitchX(config)# spanning-tree bpdufilter enable/disable • 当接收到BPDU则强制取消端口portfast

  15. Spanning-Tree Operation Example

  16. Spanning-Tree Path Cost

  17. Spanning-Tree Recalculation

  18. Per VLAN Spanning Tree Plus

  19. PVST+ 扩展的 桥 ID Bridge ID without the extended system ID Extended bridge ID with system ID System ID = VLAN

  20. Rapid Spanning Tree Protocol

  21. Default Spanning-Tree Configuration • Cisco 交换机三种类型的STPs: • PVST+ • PVRST+ • MSTP • 默认情况下在Cisco交换机上使用PVST+ : • 每个VLAN有一个独立的STP • 所有VLAN可以使用同一个交换机做根 • 但不等做负载均衡

  22. PVRST+ 配置指南 • Enable PVRST+. • 指定和配置交换机为根桥. • 指定和配置另一个交换机为备份的根桥. • 验证配置.

  23. PVRST+ 执行命令 SwitchX(config)# spanning-tree mode rapid-pvst • Configures PVRST+ SwitchX# show spanning-tree vlan vlan# [detail] • Verifies the spanning-tree configuration SwitchX# debug spanning-tree pvst+ • Displays PVST+ event debug messages

  24. 验证 PVRST+ SwitchX# show spanning-tree vlan 30 VLAN0030 Spanning tree enabled protocol rstp Root ID Priority 24606 Address 00d0.047b.2800 This bridge is the root Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 24606 (priority 24576 sys-id-ext 30) Address 00d0.047b.2800 Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 300 Interface Role Sts Cost Prio.Nbr Type -------- ----- --- --- -------- ---- Gi1/1 Desg FWD 4 128.1 P2p Gi1/2 Desg FWD 4 128.2 P2p Gi5/1 Desg FWD 4 128.257 P2p The spanning-tree mode is set to PVRST.

  25. Configuring the Root and Secondary Bridges

  26. Configuring the Root and Secondary Bridges: SwitchA SwitchA(config)# spanning-tree vlan 1 root primary • This command forces this switch to be the root for VLAN 1. SwitchA(config)# spanning-tree vlan 2 root secondary • This command configures this switch to be the secondary root for VLAN 2. OR SwitchA(config)# spanning-tree vlan # priority priority • This command statically configures the priority (increments of 4096).

  27. Configuring the Root and Secondary Bridges: SwitchB SwitchB(config)# spanning-tree vlan 2 root primary • This command forces the switch to be the root for VLAN 2. SwitchB(config)# spanning-tree vlan 1 root secondary • This command configures the switch to be the secondary root VLAN 1. OR SwitchB(config)# spanning-tree vlan # priority priority • This command statically configures the priority (increments of 4096).

  28. Summary • 冗余的交换网络拓扑包含多交换机和以太通道组 • 冗余的网络产生环路问题,例如广播风暴. • 使用STP生成无环路的网络拓扑. • 原始的STP被加强为PVST+和RSTP.

More Related