取消
显示结果 
搜索替代 
您的意思是: 
cancel
4879
查看次数
52
有帮助
8
评论
taosun2
Cisco Employee
Cisco Employee
本帖最后由 taosun2 于 2015-4-22 09:16 编辑
Max-Age参数和转发延迟可能会导致一个非常不稳定的STP拓扑。在这种情况下, 一些BPDU的丢失会导致出现环路。另一个问题,不是众所周知的, 它与桥接网络的直径有关。STP计时器的保守的默认值最大网络直径是7。在网络中最大网络直径限制远离彼此的网桥。在这种情况下,两个不同的网桥中间不能超过七个网桥。这一限制的一部分来自于BPDU携带的AGE字段。
当BPDU传播从根桥向上发出时,每次BPDU通过一个网桥时AGE字段都会增加。最终, 超出Max-Age字段时丢弃BPDU。如果根桥离一些网络中的网桥太远,会发生这个问题。这个问题会影响生成树的收敛。
要特别注意如果你打算改变STP计时器从默认值,是有危险的。如果你试图让再收敛变快,STP计时器的变化会影响网络的直径和STP的稳定性。你可以改变桥优先级来选择根桥, 也可以改变端口cost值或优先级参数来控制冗余和负载均衡。

http://www.cisco.com/c/en/us/support/docs/lan-switching/spanning-tree-protocol/10556-16.html#awkward

Awkward STP Parameter Tune and Diameter Issues
An aggressive value for the max-age parameter and the forward delay can lead to a very unstable STP topology. In such cases, the loss of some BPDUs can cause a loop to appear. Another issue that is not well known relates to the diameter of the bridge network. The conservative default values for the STP timers impose a maximum network diameter of seven. This maximum network diameter restricts how far away from each other bridges in the network can be. In this case, two distinct bridges cannot be more than seven hops away from each other. Part of this restriction comes from the age field that BPDUs carry.
When a BPDU propagates from the root bridge toward the leaves of the tree, the age field increments each time the BPDU goes though a bridge. Eventually, the bridge discards the BPDU when the age field goes beyond maximum age. If the root is too far away from some bridges of the network, this issue can occur. This issue affects convergence of the spanning tree.
Take special care if you plan to change STP timers from the default value. There is danger if you try to get faster reconvergence in this way. An STP timer change has an impact on the diameter of the network and the stability of the STP. You can change the bridge priority to select the root bridge, and change the port cost or priority parameter to control redundancy and load balancing.
实际案例说明
用户的一台核心交换机串连了8台同型号的接入层交换机,使用STP避免环路,但不幸的是问题就出现在STP上, 故障现象是MAC Flapping.
网络拓扑:
090805bnvq0q00z0es0227.png
问题分析:
如拓扑所示,当Core交换机向外每2秒发出PBDU包时,每经过一个网桥都会更加2秒,当穿过sw6时, 第一个PBDU已经是累加到14秒,当第15秒时Core交换机上的端口会从listening 状态,改变成learning状态,注意此时生成树还没有计算完整个拓扑,也就没有适当的block掉某一个端口,当Core交换机上的两个端口改变成learning状态后就开始学习MAC地址,而且这两个端口都会学习到相同的MAC 地址,此时就出现了MAC flapping。


解决方案:
解决方案有多种,个人建议直接缩小网络直径来解决,即把接入层的8台交换机,分为每4台交换机一组,分别串连到Core交换机即可。


参考
091005t5z7ozhypgvahgvq.png
STP 默认Timers
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
评论
xupeng
Cisco Employee
Cisco Employee
谢谢楼主分享
yingnxu
Cisco Employee
Cisco Employee
顶一个!{:2_30:}
Fisheryu
Cisco Employee
Cisco Employee
:D:D:D
Fisheryu
Cisco Employee
Cisco Employee
:D:D:D
chundli
Cisco Employee
Cisco Employee
lol:lol
linchen2
Community Member
赞一个
Luke Huang
Cisco Employee
Cisco Employee
STP 震荡的一个原因,谢谢楼主分享
sxsure001
Spotlight
Spotlight
谢谢 分享 赞赞
入门指南

使用上面的搜索栏输入关键字、短语或问题,搜索问题的答案。

我们希望您在这里的旅程尽可能顺利,因此这里有一些链接可以帮助您快速熟悉思科社区:









快捷链接