-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
Description
There should be a verification for config portchannel member add command in case of adding a port that has already been a member of another portchannel interface.
Currently, system just ignore such attempts but puts these new settings to running config.
In case of saving such configurations and performing reboot portchannel interfaces will be inoperable state.
Steps to reproduce the issue
1.Create two portchannel interfaces
# config portchannel add PortChannel0001
# config portchannel add PortChannel0002
Assign a port to PortChannel0001
# config portchannel member add PortChannel0001 Ethernet48
# show interfaces portchannel
Flags: A - active, I - inactive, Up - up, Dw - Down, N/A - not available,
S - selected, D - deselected, * - not synced
No. Team Dev Protocol Ports
----- --------------- ----------- -------------
0001 PortChannel0001 LACP(A)(Up) Ethernet48(S)
0002 PortChannel0002 LACP(A)(Dw) N/A
Assign the same port to other interface portchannel
# config portchannel member add PortChannel0002 Ethernet48 <== HERE must be the verification.
# show interfaces portchannel
Flags: A - active, I - inactive, Up - up, Dw - Down, N/A - not available,
S - selected, D - deselected, * - not synced
No. Team Dev Protocol Ports
----- --------------- ----------- -------------
0001 PortChannel0001 LACP(A)(Up) Ethernet48(S)
0002 PortChannel0002 LACP(A)(Dw) N/A
running config:
"PORTCHANNEL_MEMBER": {
"PortChannel0001|Ethernet48": {},
"PortChannel0002|Ethernet48": {}
},
Save configuration
# config save -y
Reload configuration
# config reload -y
Describe the results you received
Portchannel interfaces are inoperable state.
# show in portchannel
Flags: A - active, I - inactive, Up - up, Dw - Down, N/A - not available,
S - selected, D - deselected, * - not synced
No. Team Dev Protocol Ports
----- --------------- ----------- -------
0001 PortChannel0001 LACP(A)(Dw) N/A
0002 PortChannel0002 LACP(A)(Dw) N/A
Describe the results you expected
The config portchannel member add command should reject an attempt to add a port to a portchannel if that added port has already been a member of another portchannel interface.
Additional information you deem important (e.g. issue happens only occasionally)
Output of show version
SONiC Software Version: SONiC.201911.51-dea38d15
Distribution: Debian 9.13
Kernel: 4.9.0-11-2-amd64
Build commit: dea38d15
Build date: Mon Jan 4 13:38:57 UTC 2021
Built by: sw-r2d2-bot@r-build-sonic-ci02
Platform: x86_64-mlnx_msn3700c-r0
HwSKU: ACS-MSN3700C
ASIC: mellanox
Serial Number: MT1935X01905
Uptime: 14:12:20 up 1 day, 5:51, 2 users, load average: 3.09, 2.47, 2.00
Docker images:
REPOSITORY TAG IMAGE ID SIZE
docker-syncd-mlnx 201911.51-dea38d15 aaaa6191ae77 399MB
docker-syncd-mlnx latest aaaa6191ae77 399MB
docker-sonic-telemetry 201911.51-dea38d15 677d64c827c7 353MB
docker-sonic-telemetry latest 677d64c827c7 353MB
docker-router-advertiser 201911.51-dea38d15 569ab41a4654 290MB
docker-router-advertiser latest 569ab41a4654 290MB
docker-platform-monitor 201911.51-dea38d15 a5bc7ebc9b2c 666MB
docker-platform-monitor latest a5bc7ebc9b2c 666MB
docker-fpm-frr 201911.51-dea38d15 1ad8a005128e 335MB
docker-fpm-frr latest 1ad8a005128e 335MB
docker-teamd 201911.51-dea38d15 3779578c25cd 315MB
docker-teamd latest 3779578c25cd 315MB
docker-lldp-sv2 201911.51-dea38d15 52a8ee60c1c5 312MB
docker-lldp-sv2 latest 52a8ee60c1c5 312MB
docker-dhcp-relay 201911.51-dea38d15 b752e2e86795 300MB
docker-dhcp-relay latest b752e2e86795 300MB
docker-database 201911.51-dea38d15 873fd83afd69 290MB
docker-database latest 873fd83afd69 290MB
docker-snmp-sv2 201911.51-dea38d15 5379eb90ea3e 348MB
docker-snmp-sv2 latest 5379eb90ea3e 348MB
docker-orchagent 201911.51-dea38d15 1437f5b610dd 333MB
docker-orchagent latest 1437f5b610dd 333MB
docker-sflow 201911.51-dea38d15 8abc08609485 315MB
docker-sflow latest 8abc08609485 315MB
docker-nat 201911.51-dea38d15 f0ac3672d083 316MB
docker-nat latest f0ac3672d083 316MB
docker-sonic-mgmt-framework 201911.51-dea38d15 be78292b43d4 429MB
docker-sonic-mgmt-framework latest be78292b43d4 429MB