當局域網上的數據傳輸出現故障時,往往不輕易判定是鏈路故障還是端口故障。因此需要進行排錯,隔離以便修復故障。下面介紹一下簡單的判定過程:
我們以3700/2900系列交換機為例,在3700/2900交換機上,現在已經都是IOS的操作系統了。當出現端口的傳輸有問題時,可以在交換機上執行命令:
h controller Ethernet-controller <interface-number>
這條命令可以幫助判定問題是交換機端口的故障或是電纜的故障,還是由于接口卡的錯誤造成的。
在執行這條命令時,假如FCS錯不斷的增加,可能是物理層的故障,需要檢查一下傳輸介質。FCS (Frame Check Sequence)錯是以太網接口上常見的錯誤之一,它表明交換機的從鄰接設備收到的以太幀和該幀的CRC有錯。FCS用于檢查數據幀在傳輸過程中是否被破壞。假如交換機發現數據幀有FCS錯,則會將該數據幀丟棄,然后將該端口的FCS的計數器加1。
另外一個常見的錯誤是alignment錯,它表示交換機的端口所處理的數據幀錯位了。這通常是網絡端口的問題。Alignment錯是指從鄰接設備收到的數據幀的bit位不是8的倍數,同時伴有FCS錯。我們知道,數據幀的傳輸是以字節為單位的,一個字節等于8bit,所以每個數據幀的總的長度(以 bit計)都應該是8的倍數。假如數據幀的長度不是8的倍數,此時認為出現alignment錯。交換機收到alignment錯的數據幀后也會把它丟掉,同時將該端口的alignment計數器加1。
FCS錯和alignment錯通常表示物理層的錯誤,比如電纜故障,端口故障,網卡故障等等,但也可能是雙工方式不匹配造成的。
下面是一條該命令的結果,供參考:
IOSwitch01#sh controller Ethernet-controller fa0/1
Transmit Receive
5755681 Bytes 1335670 Bytes
78090 Frames 16070 Frames
75520 Multicast frames 19456789 FC S errors
1588 Broadcast frames 6011 Multicast frames
0 Pause frames 34 Broadcast frames
0 Single defer frames 0 Control frames
0 Multiple defer frames 0 Pause frames
0 1 collision frames 0 Unknown opcode frames
0 2-15 collisions 1000 Alignment errors
1 Late collisions 0 Length out of range
0 Excessive collisions 0 Symbol error frames
0 Total collisions 8 False carrier errors
0 Control frames 0 Valid frames, too small
0 VLAN discard frames 0 Valid frames, too large
0 Too old frames 0 Invalid frames, too small
72639 Tagged frames 0 Invalid frames, too large
1 Aborted Tx frames 0 Discarded frames
Transmit and Receive
5017 Minimum size frames
87837 65 to 127 byte frames
1030 128 to 255 byte frames
265 256 to 511 byte frames
0 512 to 1023 byte frames
10 1024 to 1518 byte frames
0 1519 to 1522 byte frames
上面的命令是用在較低端的交換機的,假如對于catalyst 6000和catalyst 4000交換機,可以使用命令’show interface counters errors’來查FCS錯或alignment錯。
新聞熱點
疑難解答