天天看點

靜态LACP模式下Eth-Trunk成員接口無法轉發流量的故障定位思路

作者:運維法拉令

常見原因

靜态LACP模式下Eth-Trunk成員接口無法轉發流量的常見原因:

  • Eth-Trunk接口被阻塞。
  • Eth-Trunk成員接口沒有Up。
  • Eth-Trunk接口的配置錯誤。
  • Eth-Trunk成員接口不能正常收發LACP封包。
  • 底層轉發異常。

故障診斷流程

可按照圖1排除此類故障。

圖1 靜态LACP模式下Eth-Trunk成員接口無法轉發流量

靜态LACP模式下Eth-Trunk成員接口無法轉發流量的故障定位思路

故障處理步驟

背景資訊

靜态LACP模式下Eth-Trunk成員接口無法轉發流量的故障定位思路

執行指令完成故障處理操作後,請根據系統中的配置生效模式,確定配置下發。如無特殊說明,本手冊采用配置兩階段生效模式進行描述。

  • 配置立即生效模式下,輸入指令行并鍵入Enter鍵後,配置将立即生效。
  • 配置兩階段生效模式下,請在完成配置後,執行指令commit,送出配置。

請儲存以下步驟的執行結果,以便在故障無法解決時快速收集和回報資訊。

操作步驟

  1. 檢視Eth-Trunk接口的STP狀态是否為block。
  2. 端口狀态正常是流量轉發的前提。在任意視圖下執行display stp brief指令檢視Eth-Trunk的STP State字段,确認Eth-Trunk接口是否為block狀态。
  3. <HUAWEI> display stp brief MSTID Port Role STP State Protection Cost Edged 0 10GE1/0/1 ROOT forwarding none 2000 disable 0 Eth-Trunk10 ALTE discarding none 2000 disable 0 10GE1/0/3 DESI forwarding none 2000 disable
  4. 如果顯示為discarding則為block狀态,此時資料封包無法轉發,請排查網絡中的環路。
  5. 如果Eth-Trunk接口的STP狀态不是block狀态,請執行步驟2。
  6. 檢視Eth-Trunk成員接口的實體狀态是否為Up。
  7. 成員接口處于UP狀态時才能被Eth-Trunk選中。在任意視圖下執行display interface interface-type interface-number指令檢視Eth-Trunk成員接口的實體狀态,其中current state表示接口的實體狀态。
  8. <HUAWEI> display interface 10ge 1/0/1 10GE1/0/1 current state : UP (ifindex: 4) Line protocol current state : UP
  9. 如果顯示為UP則表示接口處于正常啟動的狀态,請執行步驟3。
  10. 如果顯示不是UP,請檢查Eth-Trunk成員接口的實體鍊路、光子產品情況。
  11. 檢查Eth-Trunk接口的配置是否正确。在任意視圖下執行display eth-trunk trunk-id指令檢查活動接口數上/下限門檻值是否合理。其中Max Active-linknumber表示活動接口數上限門檻值,Least Active-linknumber表示活動接口數下限門檻值。<HUAWEI> display eth-trunk 10 Eth-Trunk10's state information is: Local: LAG ID: 10 Working Mode: Static Preempt Delay Time: 10 Hash Arithmetic: profile default System Priority: 120 System ID: 0025-9e95-7c31 Least Active-linknumber: 1 Max Active-linknumber: 2 Operating Status: up Number Of Up Ports In Trunk: 2 Timeout Period: Slow --------------------------------------------------------------------------------
  12. 如果配置的活動接口數上限門檻值少于期望轉發流量的接口,請在Eth-Trunk接口視圖下執行lacp max active-linknumber指令修改配置。如果Eth-Trunk接口下Up的成員接口數目少于配置的活動接口數下限門檻值,請在Eth-Trunk接口視圖下執行least active-linknumber指令修改配置。
  13. 如果Eth-Trunk接口的配置正确,請執行步驟4。
  14. 檢查Eth-Trunk成員接口是否能夠正常收發LACP封包。
    1. 檢視LACP協定封包的收發計數。
      1. 在使用者視圖下執行reset lacp statistics eth-trunk trunk-id指令清除原始LACP封包計數。
      2. 清除LACP的統計資訊後,以前的統計資訊将無法恢複。
      3. 在任意視圖下執行display lacp statistics eth-trunk trunk-id指令檢視LACP封包收發情況。<HUAWEI> display lacp statistics eth-trunk 10 Eth-Trunk10's PDU statistic is: ----------------------------------------------------------------- Port LacpRevPdu LacpSentPdu MarkerRevPdu MarkerSentPdu 10GE1/1/0/10 0 13 0 0 10GE1/1/0/12 13 13 0 0
      4. 這裡檢視的是LACP元件的封包處理情況,正常情況下,接收計數LacpRevPdu和發送計數LacpSentPdu都有計數。
      5. 如果沒有發送封包計數,則可能是LACP元件出了問題。
      6. 如果沒有收到封包計數,則需要排查是否收到對端的封包。
    2. 檢視LACP元件是否正常。[~HUAWEI-diagnose] display system component running-state | include LACP ----------------------------------------------------------------------------------------------------------------------- NAME CID PID Type Version Board Process State ----------------------------------------------------------------------------------------------------------------------- LACP 0x80480569 0x4804AC 0x48 2.0.2 1/1 1012 PRIMARY -----------------------------------------------------------------------------------------------------------------------
    3. 若狀态State為NULL則表示LACP元件有問題,請聯系技術支援人員處理。
    4. 檢視ACL規則是否存在且正确。
      1. 在任意視圖下執行display cpu-defend statistics指令檢視ACL命中計數。
      2. <HUAWEI> display cpu-defend statistics slot 1 | include lacp Statistics(packets) on slot 1 : -------------------------------------------------------------------------------- PacketType Total Passed Total Dropped Last Dropping Time Last 5 Min Passed Last 5 Min Dropped -------------------------------------------------------------------------------- lacp 0 0 - --------------------------------------------------------------------------------
      3. 正常情況下,lacp一行中的Total Passed和Last 5 Min Passed列中存在計數,間隔封包發送的一個周期計數會增加。如果不存在計數,或存在計數但不增加,則需進一步排查LACP的ACL規則是否存在。
      4. 在診斷視圖下執行display system tcam service指令擷取LACP的ACL規則的EntryID。
      5. LACP規則為全局下發,每個晶片下發一次。
      6. 對于CE12800&12800E&16800系列交換機:
      7. [~HUAWEI-diagnose] display system tcam service cpcar slot 1/1 | include lacp Total: 98 -------------------------------------------- PacketType Entry -------------------------------------------- LACP 26 --------------------------------------------
      8. 對于CE9800&8800&7800&6800&5800系列交換機:
      9. [~HUAWEI-diagnose] display system tcam service cpcar slot 1/1 | include lacp Total: 98 ----------------------------------------------------------------- PacketType HitPackets Entry ----------------------------------------------------------------- LACP 2354 26 -----------------------------------------------------------------
      10. 在診斷視圖下執行fediag指令檢視ACL規則是否正确。
      11. [~HUAWEI-diagnose] fediag slot 1 chip 0 "get acl entry info 26" Entry 26 Flags = 00000007 +USED +IN_HW +WANT_HW -upd -chg -new -sta Group = 2 Priority = 2063592367 Prev/Next = 67 / 68 HW entry ID = 0000001B HW priority = 05001450 Qualifiers: DstMac (7) -> da (13) 01:80:C2:00:00:02/FF:FF:FF:FF:FF:FF 00000180C2000002/0000FFFFFFFFFFFF (expected) 00000180C2000002/0000FFFFFFFFFFFF (actual) EtherType (29) -> ethertype (14) 8809/FFFF 0000000000008809/000000000000FFFF (expected) 0000000000008809/000000000000FFFF (actual)
      12. 上述顯示資訊中,如果DstMAC是0180c2000002且EtherType是8809,請執行步驟5。如果不是,請執行步驟6。
  15. 檢視底層轉發表項是否正确。
  16. 若LACP協商建立正常,成員口都為select狀态,流量仍然不通則需要檢視底層轉發表項。
  17. [~HUAWEI-diagnose] display interface Eth-Trunk 10 forwarding-table Eth-Trunk10 The Forwarding Table is NULL.
  18. 如果轉發表為空或者流量不同的接口不在該轉發表中,則說明為Eth-Trunk轉發表存在問題,請執行步驟6。
  19. 請收集如下資訊,并聯系技術支援人員。
  20. 上述步驟的執行結果。
  21. 裝置的配置檔案、日志資訊、告警資訊。

繼續閱讀