Open globaltrouble opened 3 years ago
mclagsyncd source is in sonic-swss repo, its binary is inside iccpd container and binary use platform env variable https://github.com/Azure/sonic-swss/blob/ef6b5d48297f7f19a8ec57e2d7b997fd0919bb9d/mclagsyncd/mclaglink.cpp#L191
mclagsyncd
iccpd
platform
But platform env is set only inside swss container services, for example https://github.com/Azure/sonic-buildimage/blob/7d40384c58848c368ecf7b2c520f7a17fcbc8bdb/dockers/docker-orchagent/orchagent.sh#L7
swss
ICCPD container contains mclagsyncd daemon, but do not set platform env variable.
Env variable do not set inside the iccpd container, code can't use it.
Env variable is set, inside the iccpd container, code can use it.
show version
admin@sonic:~$ show version SONiC Software Version: SONiC.hotfix_fix-iccpd-env.0-dirty-20211012.033913 Distribution: Debian 10.11 Kernel: 4.19.0-12-2-amd64 Build commit: 0d202fa9e Build date: Tue Oct 12 10:45:17 UTC 2021 Built by: user@igk-ct5-server Platform: x86_64-bfn_tna_model HwSKU: model ASIC: barefoot ASIC Count: 1 Serial Number: N/A Model Number: N/A Hardware Revision: N/A Uptime: 17:30:17 up 18 days, 6:50, 1 user, load average: 2.12, 2.15, 2.22 Docker images: REPOSITORY TAG IMAGE ID SIZE docker-snmp hotfix_fix-iccpd-env.0-dirty-20211012.033913 4b858ec17e74 456MB docker-snmp latest 4b858ec17e74 456MB docker-platform-monitor hotfix_fix-iccpd-env.0-dirty-20211012.033913 fd1e44ac7323 632MB docker-platform-monitor latest fd1e44ac7323 632MB docker-dhcp-relay latest 40badaaee0cc 427MB docker-syncd-bfn hotfix_fix-iccpd-env.0-dirty-20211012.033913 414a7127f5cb 1.1GB docker-syncd-bfn latest 414a7127f5cb 1.1GB docker-sflow hotfix_fix-iccpd-env.0-dirty-20211012.033913 7f00ae2a55e5 427MB docker-sflow latest 7f00ae2a55e5 427MB docker-teamd hotfix_fix-iccpd-env.0-dirty-20211012.033913 3e8c89f1af01 426MB docker-teamd latest 3e8c89f1af01 426MB docker-lldp hotfix_fix-iccpd-env.0-dirty-20211012.033913 ac3d82923936 454MB docker-lldp latest ac3d82923936 454MB docker-nat hotfix_fix-iccpd-env.0-dirty-20211012.033913 0b4df296a868 429MB docker-nat latest 0b4df296a868 429MB docker-database hotfix_fix-iccpd-env.0-dirty-20211012.033913 7657102f3967 414MB docker-database latest 7657102f3967 414MB docker-iccpd hotfix_fix-iccpd-env.0-dirty-20211012.033913 f0474b215b50 426MB docker-iccpd latest f0474b215b50 426MB docker-router-advertiser hotfix_fix-iccpd-env.0-dirty-20211012.033913 34dbaf8923ea 414MB docker-router-advertiser latest 34dbaf8923ea 414MB docker-fpm-frr hotfix_fix-iccpd-env.0-dirty-20211012.033913 760808468236 444MB docker-fpm-frr latest 760808468236 444MB docker-sonic-mgmt-framework hotfix_fix-iccpd-env.0-dirty-20211012.033913 d23263c286d1 569MB docker-sonic-mgmt-framework latest d23263c286d1 569MB docker-orchagent hotfix_fix-iccpd-env.0-dirty-20211012.033913 ddb2fd8bbb39 444MB docker-orchagent latest ddb2fd8bbb39 444MB docker-sonic-telemetry hotfix_fix-iccpd-env.0-dirty-20211012.033913 a056e355488c 502MB docker-sonic-telemetry latest a056e355488c 502MB docker-macsec hotfix_fix-iccpd-env.0-dirty-20211012.033913 afc942b660dc 429MB docker-macsec latest afc942b660dc 429MB
PR to fix it https://github.com/Azure/sonic-buildimage/pull/8945
PR to fix this problem was successfully merged. @zhangyanzhao Could you please close the issue??
Description
mclagsyncd
source is in sonic-swss repo, its binary is insideiccpd
container and binary useplatform
env variable https://github.com/Azure/sonic-swss/blob/ef6b5d48297f7f19a8ec57e2d7b997fd0919bb9d/mclagsyncd/mclaglink.cpp#L191But
platform
env is set only insideswss
container services, for example https://github.com/Azure/sonic-buildimage/blob/7d40384c58848c368ecf7b2c520f7a17fcbc8bdb/dockers/docker-orchagent/orchagent.sh#L7ICCPD container contains mclagsyncd daemon, but do not set
platform
env variable.Steps to reproduce the issue:
Describe the results you received:
Env variable do not set inside the iccpd container, code can't use it.
Describe the results you expected:
Env variable is set, inside the iccpd container, code can use it.
Output of
show version
:Additional information you deem important (e.g. issue happens only occasionally):
PR to fix it https://github.com/Azure/sonic-buildimage/pull/8945