home-assistant / addons

:heavy_plus_sign: Docker add-ons for Home Assistant
https://home-assistant.io/hassio/
Apache License 2.0
1.56k stars 1.51k forks source link

Matter add-on ChipStackError #3496

Closed fcastilloec closed 8 months ago

fcastilloec commented 8 months ago

Describe the issue you are experiencing

The Matter server add-on will not start after the latest update.

What type of installation are you running?

Home Assistant OS

Which operating system are you running on?

Home Assistant Operating System

Which add-on are you reporting an issue with?

Matter Server

What is the version of the add-on?

5.3.0

Steps to reproduce the issue

  1. Try to start the add-on

System Health information

System Information

version core-2024.2.5
installation_type Home Assistant Supervised
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.12.1
os_name Linux
os_version 5.10.0-27-arm64
arch aarch64
timezone America/New_York
config_dir /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 4764 Installed Version | 1.34.0 Stage | running Available Repositories | 1401 Downloaded Repositories | 19
Home Assistant Cloud logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Debian GNU/Linux 11 (bullseye) -- | -- update_channel | stable supervisor_version | supervisor-2024.02.1 agent_version | 1.6.0 docker_version | 25.0.3 disk_total | 58.0 GB disk_used | 19.0 GB healthy | true supported | true supervisor_api | ok version_api | ok installed_addons | MariaDB (2.6.1), Bookstack (2.0.2), Duck DNS (1.15.0), WireGuard (0.10.2), Dnsmasq (1.6.0), Samba Folders (12.3.0), go2rtc (1.8.5), Matter Server (5.3.0), ESPHome (2024.2.1)
Dashboards dashboards | 3 -- | -- resources | 11 views | 6 mode | storage
Recorder oldest_recorder_run | February 23, 2024 at 5:23 PM -- | -- current_recorder_run | February 29, 2024 at 10:48 AM estimated_db_size | 181.37 MiB database_engine | sqlite database_version | 3.44.2

Anything in the Supervisor logs that might be useful for us?

2024-02-29 10:52:05.956 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /addons/core_matter_server/stats - Container addon_core_matter_server is not running
2024-02-29 10:55:25.480 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /addons/core_matter_server/start - Another job is running for job group addon_core_matter_server

Anything in the add-on logs that might be useful for us?

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service banner: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
-----------------------------------------------------------
 Add-on: Matter Server
 Matter WebSocket Server for Home Assistant Matter support.
-----------------------------------------------------------
 Add-on version: 5.3.0
 You are running the latest version of this add-on.
 System: Debian GNU/Linux 11 (bullseye)  (aarch64 / raspberrypi4-64)
 Home Assistant Core: 2024.2.5
 Home Assistant Supervisor: 2024.02.1
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
s6-rc: info: service banner successfully started
s6-rc: info: service matter-server: starting
s6-rc: info: service matter-server successfully started
s6-rc: info: service legacy-services: starting
[10:55:32] INFO: Starting Matter Server...
s6-rc: info: service legacy-services successfully started
[10:55:34] INFO: Using 'eth0' as primary network interface.
[10:55:34] INFO: Successfully send discovery information to Home Assistant.
2024-02-29 10:55:38 (MainThread) INFO [matter_server.server.stack] Initializing CHIP/Matter Logging...
[1709222138.894788][126:126] CHIP:CTL: Setting attestation nonce to random value
[1709222138.895248][126:126] CHIP:CTL: Setting CSR nonce to random value
2024-02-29 10:55:38 (MainThread) CHIP_ERROR [chip.native.DL] Failed to reset WiFi statistic counts
2024-02-29 10:55:38 (MainThread) WARNING [PersistentStorage] Initializing persistent storage from file: /data/chip.json
2024-02-29 10:55:38 (MainThread) WARNING [PersistentStorage] Loading configuration from /data/chip.json...
2024-02-29 10:55:38 (MainThread) ERROR [root] Uncaught exception
Traceback (most recent call last):
  File "/usr/local/bin/matter-server", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/usr/local/lib/python3.11/site-packages/matter_server/server/__main__.py", line 171, in main
    server = MatterServer(
             ^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/matter_server/server/server.py", line 115, in __init__
    self.stack = MatterStack(self)
                 ^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/matter_server/server/stack.py", line 98, in __init__
    self._chip_stack = ChipStack(
                       ^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/chip/ChipStack.py", line 64, in wrapper
    instance[0] = cls(*args, **kwargs)
                  ^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/chip/ChipStack.py", line 271, in __init__
    res.raise_on_error()
  File "/usr/local/lib/python3.11/site-packages/chip/native/__init__.py", line 67, in raise_on_error
    raise self.to_exception()
chip.exceptions.ChipStackError: src/system/SystemLayerImplSelect.cpp:376: CHIP Error 0x000000C1: Endpoint pool full
[15:55:41] WARNING: matter-server service exited with code 134 (by signal 6).
s6-rc: info: service legacy-services: stopping
s6-rc: info: service legacy-services successfully stopped
s6-rc: info: service legacy-cont-init: stopping
s6-rc: info: service matter-server: stopping
s6-rc: info: service matter-server successfully stopped
s6-rc: info: service banner: stopping
s6-rc: info: service banner successfully stopped
s6-rc: info: service legacy-cont-init successfully stopped
s6-rc: info: service fix-attrs: stopping
s6-rc: info: service fix-attrs successfully stopped
s6-rc: info: service s6rc-oneshot-runner: stopping
s6-rc: info: service s6rc-oneshot-runner successfully stopped

Additional information

No response

Daasin commented 8 months ago

For me the add-on starts when I manually started it but the integration is broken with errors in the 'Device & Integrations' section of the frontend apl, even when reinitialising/reloading the matter integration.

My whole system seems to stop responding (with errors on the hub display) when trying to sort the matter issues out aswell.

fcastilloec commented 8 months ago

The 5.4.0 fixed the error for me. I still see mostly warnings on the log, but the add-on starts without issues and I can control my WiFi matter devices. I don't have any Thread ones, so I can't test that.

agners commented 8 months ago

@fcastilloec the update does have increased limits for the endpoint pool. Thanks for confirming that this fixed the problem for you!