パナソニックMNOシリーズにおけるリングアグリゲーション (link aggregation : ポートチャネル : ether channel)設定についてまとめます。
コマンド一覧
このシナリオで重要なコマンド一覧は以下の通りです。
Switch(config)# lacp <admin_key> <port_list> [ Manual | Active | Passive ]
仕様説明
channel 基本設定
以下のコマンドでlink aggregationを設定する事ができます。<admin_key>はchannelを表す一意なIDで、任意の値を設定する事ができます。ManualはLACPによりネゴシエーションを行わず必ずchannelになるという意味で、Activeは必ずLCAPのネゴシエーションを行うという意味で、Passiveは自らLACPを発信する事はないが相手のLACPには応じるという意味です。Cisco機と殆ど同じ感覚なので、特にマニュアルを読まなくても問題なく設定できると思います。
Switch(config)# lacp <admin_key> <port_list> [ Manual | Active | Passive ] Switch(config)# lacp system-priority <num> Switch(config)# interface <interface> Switch(config-if)# lacp port-priority <num>
LACP dicision maker
LACP dicision makerは多くのポートをLACPの管理対象としたときに、どのポートをActiveにするかを決定する仕組みです。
LCAPは最大16個のポートをLACPの管理対象とする事ができ、そのうち最大8個をActiveとする事ができます。もし、16個を超過するポートをLACPのメンバーに加えようとするとエラーが返されます。
Switch(config)#interface range GigabitEthernet 0/1 - 18 Switch(config-if-range)#channel-group 1 mode active Command rejected (Port-channel1, Gi0/17): Cannot configure interface for bundling % Interface range command failed for GigabitEthernet0/17 Command rejected (Port-channel1, Gi0/18): Cannot configure interface for bundling % Interface range command failed for GigabitEthernet0/18 Switch(config-if-range)#
LACPのメンバーのうち、Activeになる事ができるのは8つまでです。Activeになれなかったメンバーは”standby”という状態になり、Activeに障害が発生した場合の待機ポートとなります。
Switch#show etherchannel summary Flags: D - down P - bundled in port-channel I - stand-alone s - suspended H - Hot-standby (LACP only) R - Layer3 S - Layer2 U - in use f - failed to allocate aggregator M - not in use, minimum links not met u - unsuitable for bundling w - waiting to be aggregated d - default port Number of channel-groups in use: 1 Number of aggregators: 1 Group Port-channel Protocol Ports ------+-------------+-----------+----------------------------------------------- 1 Po1(SU) LACP Gi0/1(P) Gi0/2(P) Gi0/3(P) Gi0/4(P) Gi0/5(P) Gi0/6(P) Gi0/7(P) Gi0/8(P) Gi0/9(H) Gi0/10(H) Gi0/11(H) Gi0/12(H) Gi0/13(H) Gi0/14(H) Gi0/15(H) Gi0/16(H) Switch#
どのポートがActiveになるのかはLACP system-priorityとLACP port-priorityによって決定されます。まず互いにLACP system-priorityを比較し、priorityが小さい方の機器がLACP dicision makerとなり、どのポートをActiveにするのかの決定権を獲得します。
LACP system-priorityを定義するコマンドは以下の通りです。
Switch(config)# lacp system-priority <num>
LACP dicision makerとなった機器は、各ポートのLACP port-priorityを参照しpriorityが小さい順にActiveとします。LACP port-priorityを変更するコマンドは以下の通りです。
Switch(config)# interface <interface> Switch(config-if)# lacp port-priority <num>
動作確認環境
以下の構成で動作確認を行います。
[SW1:MNO] spanning-tree rst enable spanning-tree rst version rstp [SW2:Cisco] spanning-tree mode rapid-pvst
初期設定の全文は以下を参照下さい。
channel 基本設定
設定投入
Cisco, MNOそれぞれにchannelの設定を投入します。
[SW1:MNO] lacp 1 1-2 Active [SW2:cisco] interface range GigabitEthernet 0/1 - 2 channel-group 1 mode active
動作確認
channelが形成された事を確認します。
[SW1:MNO] SW1# show lacp 1 System Priority : 1 System ID : 00:C0:8F:2B:B5:F7 Key : 1 Aggregator Pri Attached Port List Standby Port List ---------- ----- -------------------------------- ---------------------------- 1 1 1-2 2 1 SW1# [SW2:cisco] SW2#show etherchannel summary Flags: D - down P - bundled in port-channel I - stand-alone s - suspended H - Hot-standby (LACP only) R - Layer3 S - Layer2 U - in use f - failed to allocate aggregator M - not in use, minimum links not met u - unsuitable for bundling w - waiting to be aggregated d - default port Number of channel-groups in use: 1 Number of aggregators: 1 Group Port-channel Protocol Ports ------+-------------+-----------+----------------------------------------------- 1 Po1(SU) LACP Gi0/1(P) Gi0/2(P) SW2#
SW1, SW2間でpingによる疎通確認を行います。
[SW1:MNO] SW1# ping 192.168.0.2 Type Ctrl-C to abort. Reply Received From : 192.168.0.2, TimeTaken : 0.10 ms Reply Received From : 192.168.0.2, TimeTaken : 5.98 ms Reply Received From : 192.168.0.2, TimeTaken : 5.98 ms --- 192.168.0.2 Ping Statistics --- 3 Packets Transmitted, 3 Packets Received, 0% Packets Loss SW1#
LACP dicision maker
事前準備
Cisco, MNO間でリンク16本によるchannelを設定します。
[SW1:MNO] no lacp 1 lacp 1 1-16 Active [SW2:cisco] interface range GigabitEthernet 0/1 - 16 channel-group 1 mode active
設定前の動作確認
port 1-8 がActiveとなっており、port 9-16がstandbyになっている事を確認します。
[SW1:MNO] SW1# show lacp 1 System Priority : 1 System ID : 00:C0:8F:2B:B5:F7 Key : 1 Aggregator Pri Attached Port List Standby Port List ---------- ----- -------------------------------- ---------------------------- 1 1 1-8 9-16 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 SW1# [SW2:cisco] SW2#show etherchannel summary Flags: D - down P - bundled in port-channel I - stand-alone s - suspended H - Hot-standby (LACP only) R - Layer3 S - Layer2 U - in use f - failed to allocate aggregator M - not in use, minimum links not met u - unsuitable for bundling w - waiting to be aggregated d - default port Number of channel-groups in use: 1 Number of aggregators: 1 Group Port-channel Protocol Ports ------+-------------+-----------+----------------------------------------------- 1 Po1(SU) LACP Gi0/1(P) Gi0/2(P) Gi0/3(P) Gi0/4(P) Gi0/5(P) Gi0/6(P) Gi0/7(P) Gi0/8(P) Gi0/9(H) Gi0/10(H) Gi0/11(H) Gi0/12(H) Gi0/13(H) Gi0/14(H) Gi0/15(H) Gi0/16(H) SW2#
障害系の動作確認
port 1を抜線します。すると、LACPのacitveメンバーが再選出され、port 2-9がActive, port10-16がstandbyとなります。
[SW1:MNO] SW1# show lacp 1 System Priority : 1 System ID : 00:C0:8F:2B:B5:F7 Key : 1 Aggregator Pri Attached Port List Standby Port List ---------- ----- -------------------------------- ---------------------------- 1 1 1 2 1 2-9 10-16 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 SW1#
LACP dicision makerの設定
SW1がLACP dicision makerとなるようSW1のlacp system-priorityを最低に設定します。また、Fa0/2がactiveメンバーから外れるようport-priorityを最大に設定します。
[SW1:MNO] lacp system-priority 0 interface Fa0/2 lacp port-priority 255
設定後の動作確認
Fa0/2がactiveメンバーから外れた事を確認します。また、System Priorityの値が1から0に減った事をも確認します。
[SW1:MNO] SW1# show lacp 1 System Priority : 0 System ID : 00:C0:8F:2B:B5:F7 Key : 1 Aggregator Pri Attached Port List Standby Port List ---------- ----- -------------------------------- ---------------------------- 1 1 1 2 255 3 1 3-10 2,11-16 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 1 13 1 14 1 15 1 16 1 SW1#