sonic-net / sonic-buildimage

Scripts which perform an installable binary image build for SONiC
Other
734 stars 1.41k forks source link

[chassis] gbysncd in feature table on linecards which have gbsyncd service running #10832

Closed arlakshm closed 2 years ago

arlakshm commented 2 years ago

Description

On Linecards where the gbsyncd container is running, gbsyncd is missing from feature table. Logs

admin@sonic:/etc/sonic$ sudo systemctl status gbsyncd
● gbsyncd.service - gbsyncd service
     Loaded: loaded (/lib/systemd/system/gbsyncd.service; enabled; vendor preset: enabled)
    Drop-In: /etc/systemd/system/gbsyncd.service.d
             └─auto_restart.conf
     Active: active (running) since Fri 2022-05-13 21:43:53 UTC; 13min ago
    Process: 1413537 ExecCondition=/usr/bin/gbsyncd-platform.sh (code=exited, status=0/SUCCESS)
    Process: 1413577 ExecStartPre=/usr/local/bin/gbsyncd.sh start (code=exited, status=0/SUCCESS)
   Main PID: 1413976 (gbsyncd.sh)
      Tasks: 3 (limit: 18986)
     Memory: 18.0M
     CGroup: /system.slice/gbsyncd.service
             ├─1413976 /bin/bash /usr/local/bin/gbsyncd.sh wait
             ├─1413977 /bin/bash /usr/bin/gbsyncd.sh wait
             └─1413978 python3 /usr/local/bin/container wait gbsyncd

May 13 21:43:53 sonic container[1413758]: read_data: config:False feature:gbsyncd fields:[('current_owner', 'none'), ('remote_state', 'none'), ('container_id', '')] val:['none', 'none', '']
May 13 21:43:53 sonic container[1413758]: container_start: gbsyncd: set_owner:local fallback:True remote_state:none
May 13 21:43:53 sonic container[1413758]: docker cmd: start for gbsyncd
May 13 21:43:53 sonic container[1413758]: container_start: END
May 13 21:43:53 sonic systemd[1]: Started gbsyncd service.
May 13 21:43:53 sonic container[1413978]: container_wait: BEGIN
May 13 21:43:53 sonic container[1413978]: read_data: config:True feature:gbsyncd fields:[('set_owner', 'local'), ('no_fallback_to_local', False), ('state', 'disabled')] val:['local', False, 'disabled']
May 13 21:43:53 sonic container[1413978]: read_data: config:False feature:gbsyncd fields:[('current_owner', 'none'), ('remote_state', 'none'), ('container_id', '')] val:['none', 'none', '']
May 13 21:43:53 sonic container[1413978]: container_wait: gbsyncd: set_owner:local ct_owner:none state:none id:gbsyncd pend=0
May 13 21:43:53 sonic container[1413978]: container_wait: END -- transitioning to docker wait
admin@sonic:/etc/sonic$

gbsyncd is missing in the feature table

admin@sonic:/etc/sonic$ show feature status
Feature         State            AutoRestart     SetOwner
--------------  ---------------  --------------  ----------
bgp             enabled          enabled
database        always_enabled   always_enabled
dhcp_relay      disabled         enabled         local
lldp            enabled          enabled
macsec          disabled         enabled
mgmt-framework  enabled          enabled
mux             always_disabled  enabled
nat             disabled         enabled
pmon            enabled          enabled
radv            enabled          enabled
sflow           disabled         enabled
snmp            enabled          enabled
swss            enabled          enabled
syncd           enabled          enabled
teamd           enabled          enabled
telemetry       enabled          enabled
admin@sonic:/etc/sonic$

This results in the monit container_checker errors

admin@sonic:/etc/sonic$ sudo monit status container_checker
Monit 5.20.0 uptime: 2d 2h 24m

Program 'container_checker'
  status                       Status failed
  monitoring status            Monitored
  monitoring mode              active
  on reboot                    start
  last exit value              4
  last output                  Unexpected running containers: gbsyncd
  data collected               Fri, 13 May 2022 21:53:44

``
<!--
     Briefly describe the problem you are having in a few paragraphs.
-->

#### Steps to reproduce the issue:
1.
2.
3.

#### Describe the results you received:

#### Describe the results you expected:

#### Output of `show version`:

(paste your output here)

#### Output of `show techsupport`:

(paste your output here or download and attach the file here )



#### Additional information you deem important (e.g. issue happens only occasionally):

<!--
     Also attach debug file produced by `sudo generate_dump`
-->
abdosi commented 2 years ago

https://github.com/sonic-net/sonic-buildimage/pull/11754

abdosi commented 2 years ago

Linked Merged PR should fix this. cc @rlhui