端口操作 第6章 Port Channel配置
4.设置交换机的load-balance方式 命令 全局配置模式 load-balance {dst-src-mac dst-src-mac-ip}
5.设置LACP协议的系统优先级 命令 全局配置模式 lacp system-priority
7. 设置LACP协议中当前端口的Timeout模式 命令 端口配置模式 lacp timeout {short | long} no lacp timeout 解释 设置当前端口LACP协议中的端口Timeout模式,no命令表示恢复为默认值。 解释 设置当前端口LACP协议中的端口优先级,no命令表示恢复为默认值。 解释 设置LACP协议的系统优先级,no命令表示恢复为默认值。 | dst-src-ip 解释 | 设置交换机的load-balance,同时作用于port-group与ECMP功能。 6.4 Port Channel举例
案例1:以LACP方式配置Port Channel。
S1
S2
6-4
端口操作 第6章 Port Channel配置 图 6-2 以LACP方式配置Port Channel
如上图所示,交换机S1上的1、2、3、4端口都是access口,将这4个端口以active方式加入group 1,交换机S2上6、8、9、10端口为access口,将这4个端口以passive方式加入group 2,将以上对应端口分别用网线相连。
配置步骤如下: Switch1#config
Switch1(config)#interface ethernet 1/0/1-4
Switch1(Config-If-Port-Range)#port-group 1 mode active Switch1(Config-If-Port-Range)#exit
Switch1(config)#interface port-channel 1 Switch1(Config-If-Port-Channel1)#
Switch2#config
Switch2(config)#port-group 2
Switch2(config)#interface ethernet 1/0/6
Switch2(Config-If-Ethernet1/0/6)#port-group 2 mode passive Switch2(Config-If-Ethernet1/0/6)#exit
Switch2(config)#interface ethernet 1/0/8-10
Switch2(Config-If-Port-Range)#port-group 2 mode passive Switch2(Config-If-Port-Range)#exit
Switch2(config)#interface port-channel 2 Switch2(Config-If-Port-Channel2)#
配置结果:
过一段时间后,shell提示端口汇聚成功,此时交换机S1的端口1、2、3、4汇聚成一个汇聚端口,汇聚端口名为Port-Channel1,交换机S2的端口6、8、9、10汇聚成一个汇聚端口,汇聚端口名为Port-Channel2,并且都可以进入汇聚接口配置模式进行配置。
案例2:以ON方式配置Port Channel。
S1
S2
图 6-3 以ON方式配置Port Channel
6-5
端口操作 第6章 Port Channel配置 如图所示,交换机S1上的1、2、3、4端口都是access口,将这4个端口以on方式加入group 1,在交换机S2上6、8、9、10端口为access口,将这4个端口以on方式加入group 2。
配置步骤如下: Switch1#config
Switch1(config)#interface ethernet 1/0/1
Switch1(Config-If-Ethernet1/0/1)#port-group 1 mode on Switch1(Config-If-Ethernet1/0/1)#exit Switch1(config)#interface ethernet 1/0/2
Switch1 (Config-If-Ethernet1/0/2)#port-group 1 mode on Switch1 (Config-If-Ethernet1/0/2)#exit Switch1 (config)#interface ethernet 1/0/3
Switch1 (Config-If-Ethernet1/0/3)#port-group 1 mode on Switch1 (Config-If-Ethernet1/0/3)#exit Switch1 (config)#interface ethernet 1/0/4
Switch1 (Config-If-Ethernet1/0/4)#port-group 1 mode on Switch1 (Config-If-Ethernet1/0/4)#exit
Switch2#config
Switch2 (config)#port-group 2
Switch2 (config)#interface ethernet 1/0/6
Switch2 (Config-If-Ethernet1/0/6)#port-group 2 mode on Switch2 (Config-If-Ethernet1/0/6)#exit
Switch2 (config)#interface ethernet 1/0/8-10
Switch2 (Config-If-Port-Range)#port-group 2 mode on Switch2 (Config-If-Port-Range)#exit
配置结果:
将交换机S1上的1、2、3、4端口依次加入port-group1后我们可以看到,以on方式加入一个组完全是强制性的,两端的交换机并不会通过交换LACP PDU来完成汇聚,汇聚也是触发式的,当敲入将端口1/0/2加入port-group1的命令时,1和2马上汇聚在一起形成port-channel1,当将端口1/0/3加入port-group1时,1和2汇聚成的port-channel1被拆散,马上1,2,3三个端口又重新汇聚成port-channel1,当将端口1/0/4加入port-group1时,1、2、3端口汇聚成的port-channel1被拆散,马上1、2、3、4端口又重新汇聚成port-channel1(需要说明的是,当有一个新的端口要加入已经汇聚成功的组时,必须先拆散原先的组,然后再能汇聚成一个新的组)。结果是交换机S1和交换机S2上的三个端口都以ON模式汇聚起来,各自形成一个汇聚端口。
6.5 Port Channel排错帮助
当配置端口聚合功能出现问题时,请检查是否是如下原因:
? 端口聚合组中的端口不具有相同的属性,即双工模式是否为全双工模式,速率是否强制
6-6
端口操作 第6章 Port Channel配置
成相同的速率,以及VLAN的属性等。如果检查不相同,则修改成相同。
? 一些命令不能在port-channel上的端口使用,包括:arp,bandwidth,ip,ip-forward
等。
6-7
端口操作 第7章 JUMBO配置
第7章 JUMBO配置
7.1 JUMBO介绍
JUMBO(超大帧)在业界现在还没有一个确定的标准(包括帧格式和帧的长度),一般将大小在1519—9000之间的帧视为超大帧。超大帧的网络实现可以将整个网络的速度提高2%到5%。JUMBO在使用上只是将交换机在收发的帧的长度增加了。但是考虑到JUMBO帧的长度问题,所以JUMBO是不送到CPU的,我们将送到CPU的JUMBO帧在收包处理中将JUMBO帧丢掉了。
7.2 JUMBO配置任务序列
1. 配置JUMBO功能使能
1. 配置JUMBO功能使能 命令 全局配置模式 jumbo enable [
解释 启用JUMBO帧的收发功能。 该命令的NO操作禁用JUMBO帧的收发功能。
7-1