Synology NAS integration periodically stops to work

From some time I’m facing strange issue with Synology integration - it stops to work and reinitiates periodically. I have RS2418+ configured for 3+ years and it was always rock solid. Somewhere like 2~3 months ago i started to experience these interruptions in communication between HA and NAS. From troubleshooting I did I can say:

  • NAS is available and all services seems to work fine during breaks. I can connect to various web services, docke applications and VMs running on NAS (including Virtual DSM, also integrated to HA that is availble 100% of the time.
  • I can ping NAS from HA terminal and no signs of connection instability or slowness.
  • I have MariaDB configured on NAS for HA recorder data and there is no service problem with DB during issues with integration.
  • Whenever communication breakdown appers I can see in log file following errors:
2024-11-17 18:13:54.913 WARNING (MainThread) [homeassistant.helpers.entity] Update of update.synologynas_dsm_update is taking over 10 seconds
2024-11-17 18:47:06.752 ERROR (MainThread) [homeassistant.components.synology_dsm.coordinator] Error fetching Synology RS2418 SynologyDSMCentralUpdateCoordinator data: Error communicating with API: {'api': None, 'code': -1, 'reason': 'Unknown', 'details': 'TimeoutError'}
2024-11-17 18:47:06.756 ERROR (MainThread) [homeassistant.components.template.template_entity] TemplateError('ValueError: Template error: as_timestamp got invalid input 'unavailable' when rendering template '{% set t = ((as_timestamp(now())-as_timestamp(states('sensor.synologynas_last_boot'))))|int(default=0) %} {{ '{:d}d {:02d}h {:02d}m'.format(t // 86400, (t // 3600) % 24, (t % 3600) // 60, (t % 3600) % 60) }}' but no default was specified') while processing template 'Template<template=({% set t = ((as_timestamp(now())-as_timestamp(states('sensor.synologynas_last_boot'))))|int(default=0) %} {{ '{:d}d {:02d}h {:02d}m'.format(t // 86400, (t // 3600) % 24, (t % 3600) // 60, (t % 3600) % 60) }}) renders=1046>' for attribute '_attr_native_value' in entity 'sensor.synologynas_uptime'

The first of these errors repets rather rarely, not even during every communication break (!), while the second is repeated multiple times aand is always followed by template error (only this one specific template for uptime).

From my dashboard I can see following chart of CPU usage, when integration fails to communicate (fin-like, smoothed periods are for timeframe with no communication and then it comes back to normal for a while):
image

That create quite regular pattern of ~10 minutes of normal work and ~30 minutes of lost connection.

When integration works properly charts look like:
image

Any idea of what might be wrong?