tomaae / homeassistant-truenas

TrueNAS integration for Home Assistant
Apache License 2.0
183 stars 16 forks source link

[Bug] frequent disconnects #154

Closed muddro1 closed 3 months ago

muddro1 commented 4 months ago

Using master, getting the following two issues:

Logger: custom_components.truenas.coordinator
Source: helpers/update_coordinator.py:347
integration: TrueNAS (documentation, issues)
First occurred: 4:14:55 PM (8 occurrences)
Last logged: 5:23:44 PM

Error fetching TrueNAS data: TrueNas Disconnected

And

Logger: custom_components.truenas.coordinator
Source: helpers/update_coordinator.py:315
integration: TrueNAS (documentation, issues)
First occurred: 4:16:08 PM (13 occurrences)
Last logged: 5:11:25 PM

Unexpected error fetching TrueNAS data: 'root_dataset'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 315, in _async_refresh
    self.data = await self._async_update_data()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/truenas/coordinator.py", line 104, in _async_update_data
    await self.hass.async_add_executor_job(self.get_pool)
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/truenas/coordinator.py", line 778, in get_pool
    self.ds["pool"][uid].pop("root_dataset")
KeyError: 'root_dataset'

Not sure if they are related.

tomaae commented 4 months ago

most likely. I will need to see debugs for this one.

github-actions[bot] commented 4 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

github-actions[bot] commented 3 months ago

This issue was closed because it has been stalled for 5 days with no activity.

muddro1 commented 3 months ago

Just an FYI, this resolved after turning off swap. Dragonfish had a swap issue issue that's due to be corrected in the next maintenance release. https://forums.truenas.com/t/dragonfish-swap-usage-high-memory-memory-leak-issues/3680/20