show interface 是思科路由器故障排查的「核磁共振」。掌握每個計數器的物理含義,才能從海量輸出中秒級定位故障。本文以 7507 平台為例,通用於 ISR/ASR/Catalyst 全系。
show interfaces fastethernet slot/port-adapter/port (如 sh int fa 1/0/0);show interfaces pos slot/port-adapter/port (如 sh int pos 2/0/0);sh int gi1/0/1、sh int te0/0/0。FastEthernet1/0/0 is up, line protocol is up
Hardware is TSWITCH, address is 00e0.f7a4.5130 (bia 00e0.f7a4.5130)
MTU 1500 bytes, BW 100000 Kbit, DLY 100 usec, rely 255/255, load 1/255
Encapsulation ARPA, loopback not set, keepalive set (10 sec)
Half-duplex, 100BaseTX
ARP type: ARPA, ARP Timeout 04:00:00
Last input 00:05:30, output 00:00:00, output hang never
Last clearing of "show interface" counters never
Queueing strategy: fifo
Output queue 0/40, 0 drops; input queue 0/75, 0 drops
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
312 packets input, 18370 bytes, 0 no buffer
Received 216 broadcasts, 0 runts, 0 giants, 0 throttles
3 input errors, 0 CRC, 0 frame, 0 overrun, 3 ignored, 0 abort
0 input packets with dribble condition detected
15490 packets output, 1555780 bytes, 0 underruns
2 output errors, 0 collisions, 2 interface resets
0 babbles, 0 late collision, 0 deferred
0 lost carrier, 0 no carrier
2 output buffer failures, 0 output buffers swapped out
| 字段 | 含義 | 告警閾值/經驗值 |
|---|---|---|
is up / line protocol is up | 物理層/數據鏈路層狀態 | up/up 正常;down/down=物理斷鏈;up/down=封裝不匹配/Keepalive 失敗/無 VLAN |
MTU | 最大傳輸單元 | 以太網 1500;巨型幀 9000+;雙端必須一致 |
BW | 帶寬參考值 (kbps),供路由協議計算開銷 | 手動 bandwidth 命令修正,影響 OSPF/EIGRP 路由選擇 |
rely 255/255 | 接口可靠性 (5分鐘滑動窗口) | <255 表示有丟包/錯誤,持續 <200 需介入 |
load 1/255 | 接口負載 (5分鐘平均) | >200 (80%) 觸發擴容/QoS 調優 |
Encapsulation | 封裝類型 (ARPA/HDLC/PPP/FR/PPPoE) | 雙端必須一致,否則 up/down |
Half-duplex, 100BaseTX | 雙工/速率模式 | 全雙工為標準;半雙工產生碰撞、晚期碰撞 |
input errors | 所有輸入錯誤總和 (runts+giants+CRC+frame+overrun+ignored) | >0 需深挖具體子項 |
CRC | 循環冗余校驗失敗 | 高 CRC = 線纜/水晶頭/端口/模塊硬件故障,優先換線/換口 |
frame | CRC 錯誤 + 非整數字節 | 通常伴隨碰撞/雙工不匹配 |
overrun | 接收速率超過硬件處理能力 | CPU/總線瓶頸,升級硬件/優化轉發 |
ignored | 接口內部緩存不足丟包 | 調大 hold-queue in / 檢查 CPU |
runts / giants | 小於 64B / 大於 1518B 的幀 | 線纜故障/雙工不匹配/惡意攻擊 |
output errors / collisions / interface resets | 輸出錯誤/碰撞/接口重置次數 | resets >0 表示接口曾凍結/重啟,檢查錯誤幀源頭 |
late collision | 發送序言後發生碰撞 | 線纜超長 (>100m) 或雙工不匹配鐵證 |
lost carrier / no carrier | 傳輸中載波丟失 | 光模塊/雙絞線/對端端口故障 |
output buffer failures | 輸出緩存分配失敗 | 內存不足/突發流量衝擊,調 buffers / 擴內存 |
parity:SONET/SDH 偶校驗錯誤,光纖品質/模塊問題;applique:子卡/模塊級錯誤;carrier transitions:載波狀態翻轉次數,>0 表示光鏈路抖動。建立 基線快照 (定期 sh int | i errors|CRC|overrun|ignored|resets 存檔),對比異常即可秒級發現退化趨勢。