For a few weeks now, I’ve been experiencing a latency of a few seconds in my scenes and in the dashboard display. For example, I press a Zigbee button, and the Zigbee lamp only turns on 3-4 seconds later. But this isn’t systematic, and generally, everything is quite responsive. In fact, it seems to happen for a few minutes every hour…
I think my mini-PC running Gladys is overloaded, but I’m not sure how to identify which process is causing the issue.
I observe this in the information sent every minute from my probes in Node-RED (ignore the label ‹ raspberri-pi4 ›, I just didn’t rename it after switching to a mini-PC):
You can see significant RAM usage (increasing it would probably help…) and especially a CPU spike from 15% to 35%, corresponding to the period when Gladys loses its responsiveness.
What can I analyze to identify the source of the problem?
Nothing else but Gladys is running on my mini-PC.
I think I’ve found the culprit: Every hour, at the time when I observe the significant slowdown of the dashboard and Gladys scenes, the « Enedis Data Synchronization » task starts and lasts more than 10 minutes!
I downloaded Gladys logs to try to spot lines related to Enedis, but I only get about 20 minutes of logs in a 330 KB file, while the Gladys system page indicates that logs will be truncated at 20 MB. That’s strange because my last Gladys restart was 17 hours ago…
And when I run « docker logs -t gladys » via SSH on my mini-PC, I don’t get any more logs.
So several questions:
- How can I configure Gladys to keep logs longer? 24 hours would seem better to be able to analyze in case of issues, right?
- How can I ensure that the culprit of my slowdowns is indeed related to Enedis?
- If the issue is indeed from there, what can I do to fix it? I thought about removing the Enedis integration and then adding it back, but:
- do I risk losing my data history, or will everything come back? I have Enedis data in Gladys since August 2022…
- will deleting and recreating the Enedis integration force me to reconfigure the hierarchy of devices in the energy tracking, since Enedis is the root of everything?
Thanks in advance for your advice!