question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ReGaHss freeze bei Gewerkeauflistung => monit restart RegaHSS

See original GitHub issue

Describe the bug RaspberryMatic freeze > monit restart RegaHSS on larger setup > timeout?

To Reproduce Steps to reproduce the behavior: See in below.

Expected behavior I Have a bigger setup ~ 140 Homematic devices. When I open “Gewerke/Bearbeiten” it seems that RaspberryMatic freeze. When I look to the log so it seems that monit run into “timeout” and is restarting RegaHSS. There is no entry in “Alarmmeldungen”. I can reproduce this.

LOG:

`

Click on Gewerke:

Dec 14 14:31:07 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:31:30 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:31:52 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:32:15 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:32:37 homematic local0.err ReGaHss: ERROR: Send failed (errno=32)! [Send():iseSysLx.cpp:1596]

Click on Bearbeiten in Gewerke

Dec 14 14:34:29 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:34:52 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:35:15 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:35:38 homematic user.warn monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:36:01 homematic user.err monit[1095]: ‘ReGaHss’ failed protocol test [HTTP] at [localhost]:8183 [TCP/IP] – HTTP: Error receiving data – Resource temporarily unavailable Dec 14 14:36:01 homematic user.info monit[1095]: ‘ReGaHss’ trying to restart Dec 14 14:36:01 homematic user.info monit[1095]: ‘ReGaHss’ restart: ‘/etc/init.d/S70ReGaHss restart’ Dec 14 14:36:11 homematic user.info ReGaHss: SIGTERM: ReGaHss Halting Dec 14 14:36:11 homematic local0.err ReGaHss: ERROR: Send failed (errno=32)! [Send():iseSysLx.cpp:1596] `

I have disabled monit with “monit unmonitor regahss” and tried again. It tooks arround 2Minutes to open “Gewerke” and another 1-2minutes to open “Gewerke/Bearbeiten” after click OK it tooks another 1-2 to close the windows. During this time it seems that RaspberryMatic is frozen but it is only very slow. When I look to the log there are no additional entries.

Screenshots If applicable, add screenshots to help explain your problem.

System information (please complete the following information):

  • Version 3.47.22.20191130
  • Hardware RaspberryPi3

Additional context

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:24 (22 by maintainers)

github_iconTop GitHub Comments

1reaction
jp112sdlcommented, Dec 18, 2019

Beim ☕️ mal schnell den Workaround durch den Skripttester gejagt:

Startzeit = 06:33:00
Endzeit   = 06:33:07

von hier noch 17 Sekunden!

Ich bin begeistert! 🎉

Stellt sich mir noch die Frage, warum man das überhaupt so:

            iProgCount = iProgCount + chnTmp.ChnDPUsageCount();
            iProgCount = iProgCount + chnTmp.ChnDPUsageCount();

gemacht hat und nicht so:

            iProgCount = iProgCount + (2 * chnTmp.ChnDPUsageCount());

Oder warum man den Result von ChnDPUsageCount() nicht in einer lokalen Variable speichert, um die ja doch sehr lange dauernden Aufrufe so gering wie möglich zu halten.

@jens-maus Kannst du erkennen, warum ChnDPUsageCount() so ewig braucht?

0reactions
jp112sdlcommented, Dec 18, 2019

welches nach der Optimierung nun in der Gewerkeauflistung immer noch dafür verantwortlich ist das diese anscheinend immer noch nicht so performant ist wie die anderen Seiten.

Das einzige, was bei mir jetzt noch dauert, ist ChnEnumDPUsagePrograms in https://github.com/eq-3/occu/blob/14b4d073ec2ad199889f29a2d3326096afbffbbc/WebUI/www/rega/pages/tabs/admin/views/functions.htm#L383-L390

Wenn ich das rausnehme, dann ist bei mir die Gewerkeliste in unter 1 Sek. geladen. Ansonsten dauert es 4 Sek.

Aber ich fürchte, das lässt sich nicht entfernen, da hier die entsprechenden Programme gefiltert werden.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found