《交換機(jī)的通道技術(shù)》
交換機(jī)通道技術(shù)是將交換機(jī)的多個(gè)端口捆綁使用,也叫端口的聚合。其作用是
提高網(wǎng)絡(luò)帶寬,增加了可靠性。
配置二層通道時(shí),首先要把捆綁的端口劃分到指定的VLAN或trunk。
配置三層通道時(shí),用no switchport關(guān)閉二層端口,設(shè)置通道IP地址。
組成通道的端口稱為成員(<8),所有成員的參數(shù)應(yīng)該一致,如工作模式、封裝
的協(xié)議、端口類型、端口花費(fèi)、優(yōu)先級(jí)等,并使用第一個(gè)端口的參數(shù)。
端口協(xié)商方式:
手動(dòng)方式:端口成員兩端模式mode為on。
自動(dòng)方式:
PAgP(Port Aggregation Protocol)Cisco設(shè)備專用聚合協(xié)議。auto模式在協(xié)
商中只收不發(fā),desirable模式收發(fā)協(xié)商的數(shù)據(jù)包。
LACP(Link aggregation Control Protocol)通用聚合協(xié)議802.3ad。active
相當(dāng)于PAgP的auto,而passive相當(dāng)于PAgP的desirable。
定義PAgP 地址的學(xué)習(xí)方法:
switch(config-if)#pagp learn-method {aggregation-port|physical-port}
aggregation-port:使用邏輯端口(通道號(hào))。
physical-port:使用物理端口,需要啟動(dòng)源MAC負(fù)載平衡方式。
定義PAgP 端口的優(yōu)先級(jí):
switch(config-if)#pagp port-priority <number>
number:取值0~255。
定義LACP 端口的優(yōu)先級(jí):
switch(config-if)#lacp port-priority <number>
number:取值0~65536。
定義LACP 系統(tǒng)的優(yōu)先級(jí):
switch(config)#lacp system-priority <number>
number:取值0~32768。
建立通道及協(xié)商模式命令
switch(config-if-range)#channel-protocol {pagp|lacp}
switch(config-if-range)#channel-group <number> mode <
{auto|desirable|on}|{active|passive}>
顯示通道信息命令:
switch#show etherchannel [<n>] {detail|summary}
其中 detail表示詳細(xì)的,summary表示綜合的。
通道端口間的負(fù)載平衡
scr-mac:源MAC地址相同的數(shù)據(jù)幀使用同一個(gè)端口轉(zhuǎn)發(fā)。
dst-mac:目的MAC地址相同的數(shù)據(jù)幀使用同一個(gè)端口轉(zhuǎn)發(fā)。
命令格式:
switch(config)#port-channel load-balance {scr-mac|dst-mac}
例題:交換機(jī)間的端口聚合
switchA#conf t
switchA(config)#int range f0/3 -6
switchA(config-if-range)#switchport mode access
switchA(config-if-range)#switchport access vlan 2
switchA(config-if-range)#channel-protocol pagp
switchA(config-if-range)#channel-group 2 mode desirable
Creating a port-channel interface Port-channel 2
switchA(config-if-range)#no shutdown
switchA(config-if-range)#exit
switchA(config)#exit
switchA#
switchB#conf t
switchB(config)#int range f0/3 -6
switchB(config-if-range)#switchport mode access
switchB(config-if-range)#switchport access vlan 2
switchB(config-if-range)#channel-protocol pagp
switchB(config-if-range)#channel-group 2 mode auto
Creating a port-channel interface Port-channel 2
switchB(config-if-range)#no shutdown
switchB(config-if-range)#exit
switchB(config)#exit
switchB#
本站僅提供存儲(chǔ)服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)
點(diǎn)擊舉報(bào)。