Breaking changes in synology dsm?

Hi.

I have been using synology dsm integration for a while and just upgraded my version of HA and noticed cameras were added to synology dsm and old synology was deprecated but all my sensors have stopped working.

I have sensors like “ sensor.synology_cpu_load_15_min”
And they all show unavailable. I assume this was a change at some point but must have completely missed it?

When did it happen sorry? Assume I just go and rename all my graphs / cards to whatever the new version of these sensors are called?

Edit
I have just looked in the integration and everything is showing unavailable so maybe it’s not sensors renamed? The drive is still working has the integration just broke?

Try removing the integration and any manual config, restart, then add the integration back again. I was having continual timeout issues before 0.116.0 and now I can configure the timeout it’s working finally properly.

Do what David said, I have it working fine on 0.116.2.

Thanks. Seems the common approach quite often! Will give it a go.

I removed integration and checked config. (nothing in config file for synology)

Restarted

Added integration again (Synology DSM)
username, password, port 5001 (https) (it wouldnt let me use 5000)
It added it successfully

Another restart.

I can see the integration but shows no devices or entities yet?

I didn’t specify a port and I suspect that is your mistake.

Do you add through the integrations page?

I have just removed it and done that with no port listed. Will see, maybe it takes a while to populate the entities?

Did you check the breaking changes before updating, this was well documented

Hence the post. I did not see any breaking changed around the synology DSM integration, only deprecation of the synology integration.

What have I missed @sparkydave?

image

It says to use the DSM now instead… Ok, maybe I have misread your original post. Ignore me.

no thats fine, yeah I have been using the synology dsm integration since it came out and its been good until now.

As yet no entities have appeared after reinstalling.

Did you uncheck SSL?

Just removed again and unticked.

Will see if that does anything. Think it was ticked last time but not sure.

Yeah it’s ticked by default so untick it and don’t enter port. I also set the timeout to 1 minute and it’s working. Check the HA log as well for error messages…

there’s a real breaking change in the Synology DSM: it won’t re-initialize after a scheduled shutdown of the server, and all entities/devices remain unavailable after that…
Has been working for years, and since 116? seems to have stopped doing that correctly. Might even call it a bug…
And we cant ‘reload’ the integration. So only can restart the HA instance to get all devices back.

seems there is something in the logs I missed. Not sure what this means though:

Log Details (ERROR)
Logger: homeassistant.config_entries
Source: components/synology_dsm/__init__.py:358
First occurred: 9:40:30 AM (1 occurrences)
Last logged: 9:40:30 AM

Error setting up entry 192.168.1.124 for synology_dsm
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 231, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 165, in async_setup_entry
    await api.async_setup()
  File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 267, in async_setup
    await self.async_update()
  File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 358, in async_update
    await self._hass.async_add_executor_job(self.dsm.update, self._with_information)
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 326, in update
    self._surveillance.update()
  File "/usr/local/lib/python3.8/site-packages/synology_dsm/api/surveillance_station/__init__.py", line 39, in update
    live_view_data = self._dsm.get(
  File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 186, in get
    return self._request("GET", api, method, params, **kwargs)
  File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 246, in _request
    raise SynologyDSMAPIErrorException(
synology_dsm.exceptions.SynologyDSMAPIErrorException: {'api': 'SYNO.SurveillanceStation.Camera', 'code': 401, 'reason': 'Invalid parameter', 'details': None}

ok so turns out I had surveillance centre running, but no cameras and this was crashing the addon!

Shut down surveillance centre, restarted and all working

1 Like

How do I “Shut down surveillance centre”. I ask cause I have the same problem you had. It’s running for some time and then it crashs…

It’s a package in package centre I think. Can shit it down from there