sonic-net / SONiC

Landing page for Software for Open Networking in the Cloud (SONiC) - https://sonic-net.github.io/SONiC/
2.27k stars 1.14k forks source link

Interfaces not seen on AS5812-54T #546

Open daisuke-k opened 4 years ago

daisuke-k commented 4 years ago

I've installed SONiC into Accton AS5812-54T, but I am unable to see any interfaces in the CLI. I also found that syncd seemed to be hung up due to error. I expect that I can see the status of every port on AS5812 by "show interfaces status" command, but the output of this command is empty. How can I fix the issue? Any help would be much appreciated.

admin@sonic:~$ show version

SONiC Software Version: SONiC.HEAD.160-dirty-20191225.055854
Distribution: Debian 9.11
Kernel: 4.9.0-9-2-amd64
Build commit: 87f70108
Build date: Wed Dec 25 06:06:31 UTC 2019
Built by: johnar@jenkins-worker-8

Platform: x86_64-accton_as5812_54t-r0
HwSKU: Accton-AS5812-54T
ASIC: broadcom
Serial Number: 581254T1921019
Uptime: 00:25:43 up 7 min,  1 user,  load average: 0.01, 0.40, 0.31

Docker images:
REPOSITORY                    TAG                              IMAGE ID            SIZE
docker-syncd-brcm             HEAD.160-dirty-20191225.055854   870028167215        428MB
docker-syncd-brcm             latest                           870028167215        428MB
docker-sonic-mgmt-framework   HEAD.160-dirty-20191225.055854   1fdb12e3bb92        330MB
docker-sonic-mgmt-framework   latest                           1fdb12e3bb92        330MB
docker-platform-monitor       HEAD.160-dirty-20191225.055854   16d57a5d666d        333MB
docker-platform-monitor       latest                           16d57a5d666d        333MB
docker-fpm-frr                HEAD.160-dirty-20191225.055854   5707a598db03        325MB
docker-fpm-frr                latest                           5707a598db03        325MB
docker-sflow                  HEAD.160-dirty-20191225.055854   4b43a8a04a0e        305MB
docker-sflow                  latest                           4b43a8a04a0e        305MB
docker-lldp-sv2               HEAD.160-dirty-20191225.055854   85241873a342        303MB
docker-lldp-sv2               latest                           85241873a342        303MB
docker-dhcp-relay             HEAD.160-dirty-20191225.055854   1a2e860a4e08        290MB
docker-dhcp-relay             latest                           1a2e860a4e08        290MB
docker-database               HEAD.160-dirty-20191225.055854   4f9a92481c9d        282MB
docker-database               latest                           4f9a92481c9d        282MB
docker-teamd                  HEAD.160-dirty-20191225.055854   ea35920828e7        305MB
docker-teamd                  latest                           ea35920828e7        305MB
docker-snmp-sv2               HEAD.160-dirty-20191225.055854   2ab1c46140a3        339MB
docker-snmp-sv2               latest                           2ab1c46140a3        339MB
docker-orchagent              HEAD.160-dirty-20191225.055854   0809f20a08f3        323MB
docker-orchagent              latest                           0809f20a08f3        323MB
docker-sonic-telemetry        HEAD.160-dirty-20191225.055854   7d7635f9ffe2        343MB
docker-sonic-telemetry        latest                           7d7635f9ffe2        343MB
docker-router-advertiser      HEAD.160-dirty-20191225.055854   6fb5f8dbc667        282MB
docker-router-advertiser      latest                           6fb5f8dbc667        282MB

admin@sonic:~$ show interfaces status
admin@sonic:~$ sudo grep syncd# /var/log/syslog
...
Dec 25 22:36:24.668650 sonic INFO syncd#supervisord: start.sh syncd: started
Dec 25 22:36:24.840016 sonic DEBUG syncd#syncd: :> syncd_main: enter
...
Dec 25 22:36:24.954831 sonic INFO syncd#syncd: [none] sai_api_initialize:223 BRCM SAI ver: [3.7.3.3], OCP SAI ver: [1.5], SDK ver: [6.5.16]
...
Dec 25 22:36:30.022887 sonic CRIT syncd#syncd: [none] _brcm_sai_dev_set:4224 Broadcom SAI detected an unsupported device id 0xb864
...
Dec 25 22:36:30.024357 sonic ERR syncd#syncd: :- processEvent: failed to execute api: create, key: SAI_OBJECT_TYPE_SWITCH:oid:0x21000000000000, status: SAI_STATUS_FAILURE
Dec 25 22:36:30.024929 sonic ERR syncd#syncd: :- syncd_main: Runtime error: :- processEvent: failed to execute api: create, key: SAI_OBJECT_TYPE_SWITCH:oid:0x21000000000000, status: SAI_STATUS_FAILURE
Dec 25 22:36:30.025174 sonic NOTICE syncd#syncd: :- notify_OA_about_syncd_exception: sending switch_shutdown_request notification to OA
Dec 25 22:36:30.025623 sonic NOTICE syncd#syncd: :- notify_OA_about_syncd_exception: notification send successfull
...
Dec 25 22:36:34.208675 sonic NOTICE syncd#syncd_request_shutdown: :- main: requested COLD shutdown
Dec 25 22:36:34.208940 sonic NOTICE syncd#syncd: :- syncd_main: is asic queue empty: 0
...
Dec 25 22:36:34.982799 sonic INFO syncd#supervisord: syncd [5] child /usr/bin/syncd exited status: 0
Dec 25 22:36:34.982869 sonic INFO syncd#supervisord: start.sh ending connection: Success
Dec 25 22:36:34.982869 sonic INFO syncd#supervisor-proc-exit-listener: Process syncd exited unxepectedly. Terminating supervisor...

sonic_dump_AS5812-54T-20191226-004011.tar.gz

Lewis-Kang commented 4 years ago

It's because the SAI package released by Broadcom doesn't support TD2+ ASIC which is used by AS5812-54T.

drewbyp commented 4 years ago

Is this also the case for the AS5812-54X? If so, do you know if there is anything that can be done to resolve it? The latest SAI package from Broadcom seems to be from 2 years ago and lists TD2 and being supported (but no mention of TD2+).

It seems strange as this particular switch is listed as compatible with SONiC but it's showing no interfaces for me.

kitinon commented 4 years ago

As @Dina0312 pointed out, this switch is listed as compatible with SONiC. So, I wonder if anyone has managed to get SONiC working on AS5812 ever?

Str1ker17 commented 3 years ago

The latest SAI package from Broadcom seems to be from 2 years ago and lists TD2 and being supported (but no mention of TD2+).

The latest SAI package is listed here: https://github.com/Azure/sonic-buildimage/blob/master/platform/broadcom/sai.mk#L2. It's much more recent than 2 years ago.

However, it does not support Trident2+ out of the box. The file libsai.so.1.0 can be binary patched (write me in Telegram: https://t.me/Str1ker I will tell you how) but after this you will need a config.bcm file - Broadcom SDK configuration file, where portmappings and phy rx tx polarity and etc. It's very difficult to craft it manually, but it's possible to take one from another, probably commercial, NOS running on the same hardware. Also, message-signaled interrupts (MSI) should be enabled in SONiC, otherwise initialization will hang or RX/TX to/from CPU won't work.

UPD: example of config.bcm is here: https://github.com/Azure/sonic-buildimage/pull/3428/files. It probably won't work, but you can give it a try.

zaprocvat commented 3 years ago

Hi all,

is AS5812-54T switch supported with the latest release of SONIC?

toreanderson commented 3 years ago

@zaprocvat I don't know, but note that latest release of Edgecore's SONiC binary build (version 202012.1) does claim to add support for the AS5812-54X. It does not say anything about the AS5812-54T, but considering that it uses the same TD2+ ASIC as the 54X does, it might be worth while testing it anyway – maybe they just forgot to add the 54T to the release notes.

hasso commented 1 year ago

Has anyone done any progress regarding this?