Cisco

HP 到 Cisco 生成樹根抖動

  • June 28, 2013

根據最近的一個問題,我最近將我的 HP (2x 2900) 和 Cisco (1x 3750) 硬體都配置為使用 MSTP 來實現互操作性。我認為這是正常的,直到我將更改應用於第三個設備(下面的 HP 交換機 1),此時生成樹根開始抖動,導致我的兩個 HP 交換機之間出現性能問題(5% 的封包遺失)。我不確定為什麼。

HP 交換機 1 A4 連接到 Cisco 1/0/1。HP Switch 2 B2 連接到 Cisco 2/0/1。HP Switch 1 A2 連接到 HP Switch 2 A1。我希望 Cisco 堆棧充當根。

編輯:


在 HP 交換機 2 中有一個特定的行 - ‘spanning-tree 1 path-cost 500000’ 我沒有添加並且是預先存在的。我不確定它是否會產生我所描述的那種影響。我更像是一個安全和監控人員,然後是網路。


編輯2:


我開始相信問題在於我在 Cisco 上的 MST 0 實例的值仍然是預設值 32768。我製作了一個圖表:生成樹 MAC 關聯 這是基於我可以為 STP 找到的每個 show 命令。我會在幾個小時後做出這個改變,看看它是否有幫助。


思科 3750 配置:

version 12.2

spanning-tree mode mst
spanning-tree extend system-id
spanning-tree mst configuration
name mstp
revision 1
instance 1 vlan 1, 40, 70, 100, 250
spanning-tree mst 1 priority 0
vlan internal allocation policy ascending

interface TenGigabitEthernet1/1/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface TenGigabitEthernet2/1/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface Vlan1
no ip address
!
interface Vlan100
ip address 192.168.100.253 255.255.255.0
!

Cisco 3750 顯示生成樹:

show spanning-tree

MST0
 Spanning tree enabled protocol mstp
 Root ID    Priority    32768
            Address     0004.ea84.5f80
            Cost        200000
            Port        53 (TenGigabitEthernet1/1/1)
            Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec

 Bridge ID  Priority    32768  (priority 32768 sys-id-ext 0)
            Address     a44c.11a6.7c80
            Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec

Interface           Role Sts Cost      Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Te1/1/1             Root FWD 2000      128.53   P2p


MST1
 Spanning tree enabled protocol mstp
 Root ID    Priority    1
            Address     a44c.11a6.7c80
            This bridge is the root
            Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec

 Bridge ID  Priority    1      (priority 0 sys-id-ext 1)
            Address     a44c.11a6.7c80
            Hello Time   2 sec  Max Age 20 sec  Forward Delay 15 sec

Interface           Role Sts Cost      Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Te1/1/1             Desg FWD 2000      128.53   P2p

Cisco 3750 顯示日誌記錄:

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan100, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan100, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up

惠普交換機 1:

; J9049A Configuration Editor; Created on release #T.13.71
vlan 1
  name "DEFAULT_VLAN"
  untagged 1-8,10,13-16,18-23,A1-A4
  ip address 100.100.100.17 255.255.255.0
  no untagged 9,11-12,17,24
  exit
vlan 100
  name "192.168.100"
  untagged 9,11-12,17,24
  tagged 1-8,10,13-16,18-23,A1-A4
  no ip address
  exit
vlan 21
  name "Users_2"
  tagged 1,A1-A4
  no ip address
  exit
vlan 40
  name "Cafe"
  tagged 1,4,7,A1-A4
  no ip address
  exit
vlan 250
  name "Firewall"
  tagged 1,4,7,A1-A4
  no ip address
  exit
vlan 70
  name "DMZ"
  tagged 1,4,7-8,13,A1-A4
  no ip address
  exit
spanning-tree
spanning-tree config-name "mstp"
spanning-tree config-revision 1
spanning-tree instance 1 vlan 1 40 70 100 250
password manager
password operator

HP Switch 1 顯示生成樹:

show spanning-tree

Multiple Spanning Tree (MST) Information

 STP Enabled   : Yes
 Force Version : MSTP-operation
 IST Mapped VLANs : 2-39,41-69,71-99,101-249,251-4094
 Switch MAC Address : 0021f7-126580
 Switch Priority    : 32768
 Max Age  : 20
 Max Hops : 20
 Forward Delay : 15

 Topology Change Count  : 363,490
 Time Since Last Change : 14 hours

 CST Root MAC Address : 0004ea-845f80
 CST Root Priority    : 32768
 CST Root Path Cost   : 200000
 CST Root Port        : 1

 IST Regional Root MAC Address : 0021f7-126580
 IST Regional Root Priority    : 32768
 IST Regional Root Path Cost   : 0
 IST Remaining Hops            : 20

 Root Guard Ports     :
 TCN Guard Ports      :
 BPDU Protected Ports :
 BPDU Filtered Ports  :
 PVST Protected Ports :
 PVST Filtered Ports  :

                 |           Prio            | Designated    Hello
 Port  Type      | Cost      rity State      | Bridge        Time PtP Edge
 ----- --------- + --------- ---- ---------- + ------------- ---- --- ----
 A1              | Auto      128  Disabled   |
 A2    10GbE-CX4 | 2000      128  Forwarding | 0021f7-126580 2    Yes No
 A3    10GbE-CX4 | Auto      128  Disabled   |
 A4    10GbE-SR  | Auto      128  Disabled   |

HP Switch 1 Logging:我刪除了日期/時間欄位,因為它們不准確(這些交換機上沒有配置 NTP)

00839 stp: MSTI 1 Root changed from 0:a44c11-a67c80 to 32768:0021f7-126580
00839 stp: MSTI 1 Root changed from 32768:0021f7-126580 to 0:a44c11-a67c80
00842 stp: MSTI 1 starved for an MSTI Msg Rx on port A4 from 0:a44c11-a67c80
00839 stp: MSTI 1 Root changed from 0:a44c11-a67c80 to 32768:0021f7-126580
00839 stp: MSTI 1 Root changed from 32768:0021f7-126580 to 0:a44c11-a67c80
00839 stp: MSTI 1 Root changed from 0:a44c11-a67c80 to ...

HP 交換機 2 配置:

; J9146A Configuration Editor; Created on release #W.14.49

vlan 1
  name "DEFAULT_VLAN"
  untagged 1,3-17,21-24,A1-A2,B2
  ip address 100.100.100.36 255.255.255.0
  no untagged 2,18-20,B1
  exit
vlan 100
  name "192.168.100"
  untagged 2,18-20
  tagged 1,3-17,21-24,A1-A2,B1-B2
  no ip address
  exit
vlan 21
  name "Users_2"
  tagged 1,A1-A2,B2
  no ip address
  exit
vlan 40
  name "Cafe"
  tagged 1,13-14,16,A1-A2,B2
  no ip address
  exit
vlan 250
  name "Firewall"
  tagged 1,13-14,16,A1-A2,B2
  no ip address
  exit
vlan 70
  name "DMZ"
  tagged 1,13-14,16,A1-A2,B2
  no ip address
  exit
logging 192.168.100.18
spanning-tree
spanning-tree 1 path-cost 500000
spanning-tree config-name "mstp"
spanning-tree config-revision 1
spanning-tree instance 1 vlan 1 40 70 100 250

HP Switch 2 生成樹:

show spanning-tree

Multiple Spanning Tree (MST) Information

 STP Enabled   : Yes
 Force Version : MSTP-operation
 IST Mapped VLANs : 2-39,41-69,71-99,101-249,251-4094
 Switch MAC Address : 0024a8-cd6000
 Switch Priority    : 32768
 Max Age  : 20
 Max Hops : 20
 Forward Delay : 15

 Topology Change Count  : 21,793
 Time Since Last Change : 14 hours

 CST Root MAC Address : 0004ea-845f80
 CST Root Priority    : 32768
 CST Root Path Cost   : 200000
 CST Root Port        : A1

 IST Regional Root MAC Address : 0021f7-126580
 IST Regional Root Priority    : 32768
 IST Regional Root Path Cost   : 2000
 IST Remaining Hops            : 19

 Root Guard Ports     :
 TCN Guard Ports      :
 BPDU Protected Ports :
 BPDU Filtered Ports  :
 PVST Protected Ports :
 PVST Filtered Ports  :

                 |           Prio            | Designated    Hello
 Port  Type      | Cost      rity State      | Bridge        Time PtP Edge
 ----- --------- + --------- ---- ---------- + ------------- ---- --- ----
 A1    10GbE-CX4 | 2000      128  Forwarding | 0021f7-126580 2    Yes No
 A2    10GbE-CX4 | Auto      128  Disabled   |
 B1    SFP+SR    | 2000      128  Forwarding | 0024a8-cd6000 2    Yes No
 B2              | Auto      128  Disabled   |

HP Switch 2 日誌記錄:我刪除了日期/時間欄位,因為它們不准確(這些交換機上沒有配置 NTP)

00839 stp: CST Root changed from 32768:0021f7-126580 to 32768:0004ea-845f80
00839 stp: IST Root changed from 32768:0021f7-126580 to 32768:0024a8-cd6000
00839 stp: CST Root changed from 32768:0004ea-845f80 to 32768:0024a8-cd6000
00839 stp: CST Root changed from 32768:0024a8-cd6000 to 32768:0004ea-845f80
00839 stp: CST Root changed from 32768:0004ea-845f80 to 32768:0024a8-cd6000
00435 ports: port B1 is Blocked by STP
00839 stp: CST Root changed from 32768:0024a8-cd6000 to 32768:0021f7-126580
00839 stp: IST Root changed from 32768:0024a8-cd6000 to 32768:0021f7-126580
00839 stp: CST Root changed from 32768:0021f7-126580 to 32768:0004ea-845f80

哇.. 經過所有研究後發現我所缺少的只是將 MST 0 實例值設置為低於預設值。一旦我將其設置為 4096,所有顯示生成樹配置開始按預期執行,將 Cisco mac 顯示為根。

GerryEgan 的解決方案將起作用,因為它還將 MST 0 實例更改為較低的值。但是,我最終希望能夠同時使用 10 個千兆鏈路,一個用於 VLAN 1,一個用於 VLAN 100。考慮到最終目標,這個通用設置是粗略的。我沒有將它包含在問題中,因為它並不真正相關 - 我迫切需要任何解決方案。

總之,為了配置我使用的這個設置:

思科 3750

spanning-tree mode mst
spanning-tree extend system-id
spanning-tree mst configuration
name mstp
revision 1
instance 1 vlan 1, 40, 70, 100, 250
spanning-tree mst 1 priority 0
spanning-tree mst 0 priority 4096

惠普交換機

spanning-tree
spanning-tree config-name "mstp"
spanning-tree config-revision 1
spanning-tree instance 1 vlan 1 40 70 100 250

你能把MST實例號改成0嗎?我認為這可能會導致您的問題,MST 預設執行實例 0,因此您創建了兩個實例,實例 1 與您已映射的 vlan 和實例 0 與所有其他實例。根據您的 Cisco 配置判斷,您應該只需要一個實例:

spanning-tree mst configuration
name mstp
revision 1
instance 0 vlan 1, 40, 70, 100, 250
spanning-tree mst 0 root primary

奇怪的是您的根在顫動,但您只設置了實例 1 的優先級而不是 0。將其全部移動到實例 0,並將 HP 開關上的 MST 實例 0 的優先級設置為高於預設值。那麼只要它在網路上,根就永遠是 3750。

在 HP 交換機上:

spanning-tree
spanning-tree config-name "mstp"
spanning-tree config-revision 1
spanning-tree instance 0 vlan 1 40 70 100 250
spanning-tree priority 36864

生成樹路徑成本命令可能被配置為阻止 HP2 成為根:

語法:生成樹<埠列表>路徑成本<自動| 1..200000000 >

分配單個埠成本,交換機使用該成本來確定給定生成樹中哪些埠正在轉發埠。在預設配置 ( auto ) 中,交換機根據埠類型確定埠的路徑成本: –

10 Mbps:2000000 –

100 Mbps:200000 –

1 Gbps:20000

有關路徑成本值與執行 802.1D STP 的設備的兼容性資訊,請參閱第 4-17 頁的“路徑成本注意事項”(預設值:自動)。

來自HP 高級流量管理指南第 138 頁。如果您沒有添加路徑成本語句,我將刪除它並在您希望成為根的交換機上將網橋優先級設置得更高。如果那是思科,那麼您已經接受了我的命令。

引用自:https://serverfault.com/questions/455731