Shellys bremsen FHEM aus?

Begonnen von Ruggy, 13 April 2025, 17:47:43

Vorheriges Thema - Nächstes Thema

Ruggy

Hallo,

ich habe schon längere Zeit Probleme mit meinen teilweise langsamen FHEM und noch keine Lösung gefunden.
Evlt. kann mir jemand helfen, die Bremser zu finden?

Ich verwende Shellys 3EM um den Verbrauch verschiedener Stromkreise zu messen, 2 Shellys für die Steuerung einer Infrarotheizung und ein Shelly für ein Balkonkraftwerk.
Aufgrund des Installationsorts loggen sich die Shellys in zwei verschiedene Fritzbox Router ein.

Vermutlich liegt es an den Shellys, weil Freezemon im Logfile dies so anzeigt.

2025.04.13 17:05:42 1: [Freezemon] myFreezemon: possible freeze starting at 17:05:39, delay is 3.533 possibly caused by: tmr-Shelly_status(Shelly3EM_Stodl_Strom) tmr-Shelly_status(Balkonkraftwerk) tmr-HttpUtils_TimeoutErr(N/A)
2025.04.13 17:08:58 1: [Freezemon] myFreezemon: possible freeze starting at 17:06:07, delay is 72.201 possibly caused by: no bad guy found :-(
2025.04.13 17:08:59 1: [Freezemon] myFreezemon: possible freeze starting at 17:07:20, delay is 99.571 possibly caused by: tmr-Shelly_status(shelly_IR_EG_Schlaf_vorne) tmr-Shelly_status(Balkonkraftwerk) tmr-HMUARTLGW_CheckCredits(myHmUART) tmr-Shelly_status(Shelly_IR_EG_Schlaf_hinten) tmr-FW_closeInactiveClients(N/A) tmr-HUEBridge_GetUpdate(deCONZ) tmr-CODE(0x6946500)(SIGNALduino_KeepAlive) tmr-Shelly_status(Shelly3EM_OG_Strom) tmr-Shelly_status(Shelly3EM_EG_Heizung) tmr-Shelly_status(Shelly3EM_OG_Heizung)

Hier noch ein Auszug der Logfile ein paar Minuten später:

2025.04.13 17:16:35 1: [Freezemon] myFreezemon: possible freeze starting at 17:13:41, delay is 174.273 possibly caused by: tmr-Shelly_status(shelly_IR_EG_Schlaf_vorne) tmr-Shelly_status(Shelly_IR_EG_Schlaf_hinten) tmr-Shelly_status(Shelly3EM_EG_Heizung)
2025.04.13 17:16:37 1: [Freezemon] myFreezemon: possible freeze starting at 17:16:36, delay is 1.314 possibly caused by: tmr-Shelly_status(Shelly3EM_OG_Strom) tmr-HMUARTLGW_CheckCredits(myHmUART) tmr-Shelly_status(Balkonkraftwerk) tmr-HttpUtils_TimeoutErr(N/A) tmr-FW_closeInactiveClients(N/A) tmr-HUEBridge_GetUpdate(deCONZ) tmr-CODE(0x6946500)(SIGNALduino_KeepAlive) tmr-Shelly_status(Shelly3EM_Stodl_Strom) tmr-Shelly_status(Shelly3EM_OG_Heizung)

Wenn FHEM "in Ruhe gelassen wird" werden im Log keine Fehler angezeigt.
Im Raum "Stromverbrauch" befinden sich alle Shellys. In diesen Raum werden beim Aufruf auch die SVG-Logs angezeigt.
Wenn ich diesen Raum aufrufe und danach erneut oder hieraus ein einzelnes Shelly device aufrufe, hängt FHEM.
(siehe Freezemon im Logfile).

In den einzelnen Shellys ist die network_rssi zwischen -60 und -74. In den Routern selber wird eine gute bis sehr gute Empfangsfeldstärke angezeigt.

Hier als Beispiel das List von einem Shelly:
Internals:
   DEF        192.168.1.51
   FUUID      63622704-f33f-f59f-85c5-b8c702338c3b5158
   INTERVAL   35
   NAME       Shelly3EM_OG_Strom
   NR         193
   NTFY_ORDER 50-Shelly3EM_OG_Strom
   SHELLYID   BCFF4DFD0F7D
   STATE      heute bisher: 2.8449 kWh
   TYPE       Shelly
   eventCount 44781
   units      0
   Helper:
     DBLOG:
       Gesamtverbrauch_kWh:
         DbLog:
           TIME       1744547906.82553
           VALUE      10282.2791
       energyReturned_0:
         DbLog:
           TIME       1744485167.23458
           VALUE      0
       energyReturned_1:
         DbLog:
           TIME       1744485167.23458
           VALUE      0
       energyReturned_2:
         DbLog:
           TIME       1744557519.51251
           VALUE      85173.5
       energy_0:
         DbLog:
           TIME       1744559015.1308
           VALUE      3418276.6
       energy_1:
         DbLog:
           TIME       1744559015.1308
           VALUE      3915845.7
       energy_2:
         DbLog:
           TIME       1744559015.1308
           VALUE      2948508.9
       energy_TTL:
         DbLog:
           TIME       1744559015.7259
           VALUE      10282631.2
       energy_returned_0:
         DbLog:
           TIME       1743939331.82039
           VALUE      0
       energy_returned_1:
         DbLog:
           TIME       1743939331.82039
           VALUE      0
       energy_returned_2:
         DbLog:
           TIME       1744557538.90704
           VALUE      85173.5
       energy_returned_TTL:
         DbLog:
           TIME       1744557538.90704
           VALUE      85173.5
       powerFactor_0:
         DbLog:
           TIME       1743939331.82039
           VALUE      0.79
       powerFactor_1:
         DbLog:
           TIME       1743939331.82039
           VALUE      0.91
       powerFactor_2:
         DbLog:
           TIME       1743939331.82039
           VALUE      -0.95
       power_0:
         DbLog:
           TIME       1744558647.8921
           VALUE      15.98
       power_1:
         DbLog:
           TIME       1744557552.46132
           VALUE      21.31
       power_2:
         DbLog:
           TIME       1744558729.92344
           VALUE      58.84
       power_TTL:
         DbLog:
           TIME       1744558664.17655
           VALUE      93.89
       power_TTLc:
         DbLog:
           TIME       1744558664.17655
           VALUE      93.89
       statGesamtverbrauch_kWhDay:
         DbLog:
           TIME       1744548395.56525
           VALUE      2.5133
       statGesamtverbrauch_kWhDayLast:
         DbLog:
           TIME       1744495195.1093
           VALUE      3.9093
       statGesamtverbrauch_kWhHour:
         DbLog:
           TIME       1744485167.23458
           VALUE      0.0365
       statGesamtverbrauch_kWhHourLast:
         DbLog:
           TIME       1744376395.07302
           VALUE      0.1260
       statGesamtverbrauch_kWhMonth:
         DbLog:
           TIME       1744547906.82553
           VALUE      116.2651
       statGesamtverbrauch_kWhYear:
         DbLog:
           TIME       1744547906.82553
           VALUE      1161.7546
   OLDREADINGS:
   READINGS:
     2025-04-13 17:43:35   Gesamtverbrauch_kWh 10282.6312
     2025-04-13 17:43:35   Total_Energy    10197457.7
     2024-11-20 21:50:35   ap              disabled open
     2024-11-20 21:50:35   ap_name         shellyem3-BCFF4DFD0F7D
     2025-04-13 17:44:10   apparentpower_0 39.3
     2025-04-13 17:44:10   apparentpower_1 45.0
     2025-04-13 17:44:10   apparentpower_2 145.2
     2024-11-20 21:50:35   auto_off        0 - disabled
     2024-11-20 21:50:35   auto_on         0 - disabled
     2022-11-02 09:15:00   cloud           disabled
     2024-02-16 00:22:48   coiot           enabled
     2024-02-16 00:22:48   coiot_period    15
     2025-04-13 17:37:44   current_0       0.17
     2025-04-13 17:43:35   current_1       0.19
     2025-04-13 17:38:19   current_2       0.64
     2025-04-12 21:12:47   energyReturned_0 0
     2025-04-12 21:12:47   energyReturned_1 0
     2025-04-13 17:18:39   energyReturned_2 85173.5
     2025-04-13 17:43:35   energy_0        3418276.6
     2025-04-13 17:43:35   energy_1        3915845.7
     2025-04-13 17:43:35   energy_2        2948508.9
     2025-04-13 17:43:35   energy_TTL      10282631.2
     2025-04-06 13:35:31   energy_returned_0 0
     2025-04-06 13:35:31   energy_returned_1 0
     2025-04-13 17:18:58   energy_returned_2 85173.5
     2025-04-13 17:18:58   energy_returned_TTL 85173.5
     2025-04-13 02:00:50   error           connect to http://192.168.1.51:80 timed out
     2023-11-12 11:51:34   firmware        v1.14.0
     2025-04-06 13:35:31   firmware_ID     20230913-114244/v1.14.0-gcb84623
     2024-11-20 21:50:35   firmware_current v1.14.0
     2025-04-12 21:13:24   firmware_updIcon B
     2025-04-12 21:13:24   firmware_updText check for beta-version
     2024-11-20 21:50:35   login           open
     2025-04-06 13:35:31   mac             BC:FF:4D:FD:0F:7D
     2025-04-06 13:35:31   model_ID        SHEM-3
     2025-04-06 13:35:31   model_family    Gen1
     2025-04-06 13:35:31   model_function  energy meter
     2025-04-06 13:35:31   model_name      Shelly 3EM
     2025-04-13 02:01:25   network         <html>connected to <a href="http://192.168.1.51">192.168.1.51</a></html>
     2025-04-06 13:35:28   network_DNS     shellyem3-OG-Strom
     2025-04-13 02:01:25   network_connection online
     2025-04-13 02:00:50   network_disconnects 4608
     2025-03-25 21:52:00   network_ip-address 192.168.1.51
     2025-04-13 17:39:29   network_rssi    -75
     2025-03-22 19:30:12   network_ssid    DAHOAM
     2024-02-16 00:22:48   network_threshold -70
     2024-11-20 21:50:35   network_wifi_roaming disabled
     2025-04-06 13:35:31   overpower_0     off
     2025-04-06 13:35:31   overpower_1     -
     2025-04-06 13:35:31   overpower_2     -
     2025-04-13 17:37:44   powerFactor_0   0.42
     2025-04-13 17:43:00   powerFactor_1   0.48
     2025-04-13 17:40:40   powerFactor_2   0.4
     2025-04-13 17:44:20   power_0         16.43
     2025-04-13 17:44:20   power_1         22.03
     2025-04-13 17:44:20   power_2         58.38
     2025-04-13 17:44:10   power_TTL       96.16
     2025-04-13 17:44:10   power_TTLc      96.16
     2025-04-13 17:44:10   reactivepower_0 35.7
     2025-04-13 17:44:10   reactivepower_1 39.5
     2025-04-13 17:44:10   reactivepower_2 133.1
     2025-03-22 19:30:12   relay           off
     2025-03-22 19:30:12   source          input
     2025-04-13 17:43:35   statGesamtverbrauch_kWh Hour: 0.0877 Day: 2.8449 Month: 116.6174 Year: 1162.1069
     2025-04-13 17:43:35   statGesamtverbrauch_kWhDay 2.8449
     2025-04-12 23:59:55   statGesamtverbrauch_kWhDayLast 3.9093
     2025-04-13 17:43:35   statGesamtverbrauch_kWhHour 0.0877
     2025-04-13 16:59:55   statGesamtverbrauch_kWhHourLast 0.1161
     2025-04-13 16:59:55   statGesamtverbrauch_kWhLast Hour: 0.1161 Day: 3.9093 Month: 325.1561 Year: 4015.8888
     2025-04-13 17:43:35   statGesamtverbrauch_kWhMonth 116.6174
     2025-03-31 23:59:55   statGesamtverbrauch_kWhMonthLast 325.1561
     2025-04-13 17:43:35   statGesamtverbrauch_kWhYear 1162.1069
     2024-12-31 23:59:55   statGesamtverbrauch_kWhYearLast 4015.8888
     2024-02-15 17:57:42   statStateDay    initialized: 00:00:00 initialized_Count: 1 (since: 2024-02-15_17:57:42)
     2024-02-15 17:57:42   statStateMonth  initialized: 00:00:00 initialized_Count: 1 (since: 2024-02-15_17:57:42)
     2024-02-15 17:57:42   statStateYear   initialized: 00:00:00 initialized_Count: 1 (since: 2024-02-15_17:57:42)
     2025-04-13 02:01:25   state           off
     2025-03-22 19:30:12   timer           0
     2025-04-13 17:44:10   uptime          73888
     2025-04-13 17:44:10   voltage_0       230.02
     2025-04-13 17:44:10   voltage_1       230.39
     2025-04-13 17:44:10   voltage_2       229.35
     2024-11-20 21:50:36   webhook_cnt     0 / 0 / 0
     2024-10-14 19:04:03   webhook_ver     0
   helper:
     Sets       config interval password reboot:noArg update:noArg name clear:disconnects,error,responsetimes actions on off toggle on-for-timer off-for-timer
     StatusCall 0
     _98_statistics myStatDevice
     settings_time 1744559015.93844
     timer      0
     bm:
       Shelly_Get:
         cnt        6
         dmx        -1000
         dtot       0
         dtotcnt    0
         mTS        11.04. 18:50:15
         max        0.000466108322143555
         tot        0.0013422966003418
         mAr:
           HASH(0x612fdf8)
           Shelly3EM_OG_Strom
           ?
       Shelly_Notify:
         cnt        595348
         dmx        -1000
         dtot       0
         dtotcnt    0
         mTS        06.04. 18:27:12
         max        0.0102889537811279
         tot        14.9018082618713
         mAr:
           HASH(0x612fdf8)
           HASH(0x6236430)
       Shelly_Set:
         cnt        2920
         dmx        -1000
         dtot       0
         dtotcnt    0
         mTS        13.04. 09:34:52
         max        0.131827116012573
         tot        70.9590561389923
         mAr:
           HASH(0x612fdf8)
           Shelly3EM_OG_Strom
           ?
Attributes:
   event-on-change-reading statGesamt.*:0.5,Gesamtverbrauch_kWh:0.5,power.*:3,energy.*
   icon       measure_power
   interval   35
   model      shelly3em
   room       Stromverbrauch
   stateFormat heute bisher: statGesamtverbrauch_kWhDay kWh
   userReadings Gesamtverbrauch_kWh:(energy_0:.*|energy_1:.*|energy_2:.*) {(ReadingsNum("$name","energy_2",0)+ReadingsNum("$name","energy_1",0)+ReadingsNum("$name","energy_0",0))/1000}

Danke
Grüße
Ruggy

passibe

Das wird jetzt überhaupt kein konstruktiver Beitrag, sorry.
Aber: Wieso nicht die Shellies per MQTT einbinden? Das spart irgendwelches HTTP-Zeug. (Habe den Sinn von diesem Shelly-Modul noch nie verstanden.)

betateilchen

Zitat von: passibe am 14 April 2025, 00:02:47(Habe den Sinn von diesem Shelly-Modul noch nie verstanden.)

Ich auch nicht.
-----------------------
Formuliere die Aufgabe möglichst einfach und
setze die Lösung richtig um - dann wird es auch funktionieren.
-----------------------
Lesen gefährdet die Unwissenheit!

Beta-User

Mir fehlt allerdings auch das Verständnis für diese eigenwilligen MQTT-Implementierungen der Shelly-firmware...
Von daher kann ich gut verstehen, dass man sich das auch nicht unbedingt antun will ;D .
Server: HP-elitedesk@Debian 12, aktuelles FHEM@ConfigDB | CUL_HM (VCCU) | MQTT2: ZigBee2mqtt, MiLight@ESP-GW, BT@OpenMQTTGw | ZWave | SIGNALduino | MapleCUN | RHASSPY
svn: u.a Weekday-&RandomTimer, Twilight,  div. attrTemplate-files, MySensors

RalfRog

#4
Einfach mal so als Idee....
35 Sekunden Abfrage Intervall ist ja schon recht kurz.
Wenn du mal 2-3 Minuten (oder 5) wählst und die SVGs in einen anderen Raum legst - hängt Fhem dann auch wenn du aus dem Raum heraus die Shellies aufrufst?

Vielleicht gibt das Ideen um das Problem einzugrenzen.

Gruß Ralf

EDIT
P.S. Daher lasse ich meineGen1-Shellies per ColIT und Shelly-Monitor ihre Werte selbstständig ohne Poll senden.
FHEM auf Proxmox VM Bookworm (Futro S740) - nanoCUL, HM-MOD-RPI-PCB und MAX!Cube über LAN
HM- Fensterkontakte, UP-Schalter, Bewegungsmelder und ein Rauchmelder sowie Shelly 3EM, 1PM, PlugS und IT Schaltsteckdosen