DBLog Error table history - DBD::mysql::st execute_array failed

Begonnen von reibuehl, 11 März 2024, 19:03:15

Vorheriges Thema - Nächstes Thema

reibuehl

Seit einem FHEM update heute morgen habe ich ständig DBLog Fehlermeldungen wie diese im Log:

2024.03.11 18:43:13 2: logdb - Error table history - DBD::mysql::st execute_array failed: executing 17544 generated 1 errors [for Statement "INSERT INTO history (TIMESTAMP, DEVICE, TYPE, EVENT, READING, VALUE, UNIT) VALUES (?,?,?,?,?,?,?)"] at ./FHEM/93_DbLog.pm line 3241.
Das DBLog device sieht so aus:

Internals:
   COLUMNS    field length used for Device: 64, Type: 64, Event: 512, Reading: 64, Value: 128, Unit: 32
   CONFIGURATION ./db.conf
   DEF        ./db.conf .*:.*
   FD         5
   FUUID      5c59d11a-f33f-3bc6-9ea4-ff4afba2213b5a09
   FVERSION   93_DbLog.pm:v5.9.6-s28628/2024-03-09
   MODE       synchronous
   MODEL      MYSQL
   NAME       logdb
   NR         2
   NTFY_ORDER 50-logdb
   PID        285358
   REGEXP     .*:.*
   SBP_PID    285359
   SBP_STATE  running
   STATE      connected
   TYPE       DbLog
   UTF8       1
   dbconn     mysql:database=fhem;host=bilbo.lan.buehl.net;port=3306
   dbuser     fhemuser
   eventCount 1962
   HELPER:
     COLSET     1
     DEVICECOL  64
     EVENTCOL   512
     LONGRUN_PID 1710179256.29423
     OLDSTATE   connected
     PACKAGE    main
     READINGCOL 64
     TC         current
     TH         history
     TYPECOL    64
     UNITCOL    32
     VALUECOL   128
     VERSION    5.9.6
   Helper:
     DBLOG:
       CacheUsage:
         logdb:
           TIME       1710177830.43507
           VALUE      0
       state:
         logdb:
           TIME       1710179256.2938
           VALUE      connected
   OLDREADINGS:
   READINGS:
     2023-01-14 21:23:39   CacheOverflowLastNum 0
     2021-07-10 11:34:41   CacheOverflowLastState normal
     2024-03-11 18:47:36   CacheUsage      0
     2017-07-01 17:37:53   lastReduceLogResult
     2024-03-11 18:47:36   state           connected
Attributes:
   DbLogSelectionMode Exclude/Include
   DbLogType  History
   icon       system_backup
   room       Logfiles

Ein set logdb configCheck zeigt m.M.n. auch nichts auffälliges:
Available Drivers in your system

DBD::DBM, DBD::ExampleP, DBD::File, DBD::Gofer, DBD::Mem, DBD::Proxy, DBD::Sponge, DBD::mysql

Result of version check

Used Perl version: 5.32.1
Used DBI (Database independent interface) version: 1.643
Used DBD (Database driver) version mysql: 4.050
Used DbLog version: 5.9.6
Your local DbLog module is up to date.
Rating:
Recommendation: Update of DbLog is not needed.
Your DBD version fulfills UTF8 support, no need to update DBD.

Result of configuration read check

Connection parameter store type: file
Connection parameter: Connection -> mysql:database=fhem;host=bilbo.lan.buehl.net;port=3306, User -> fhemuser, Password -> read o.k.
Rating:

Result of connection check

Connection to database fhem successfully done.
The time required to establish the connection was 0.0021 seconds.
Rating:
Recommendation: settings o.k.

Result of collation check

Collation used by Client (connection): UTF8MB4_BIN
Collation used by DB fhem: UTF8MB4_BIN
Rating:
Recommendation: settings o.k. Your DBD version fulfills UTF8 support, no need to update DBD.

Result of insert mode check

Insert mode of DbLog-device logdb is: Array
Rating:
Recommendation: settings o.k.

Result of plot generation method check

WEB: plotfork=1 / plotEmbed=2 / longpollSVG=0
WEBphone: plotfork=1 / plotEmbed=2 / longpollSVG=0
WEBtablet: plotfork=1 / plotEmbed=2 / longpollSVG=0

Rating:
Recommendation: settings o.k.

Result of table 'history' check

Column width set in table history: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Column width used by device logdb: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Rating:
Recommendation: settings o.k.

Result of table 'current' check

Column width set in table current: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Column width used by device logdb: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 64, 'VALUE' = 128, 'UNIT' = 32
Rating:
Recommendation: settings o.k.

Result of check 'Search_Idx' availability

Index 'Search_Idx' exists and contains recommended fields 'DEVICE', 'TIMESTAMP', 'READING'.
Rating:
Recommendation: settings o.k.

Result of check 'Report_Idx' availability for DbRep-devices

At least one DbRep-device assigned to logdb is used. Index 'Report_Idx' exists and contains recommended fields 'TIMESTAMP', 'READING'.
Rating:
Recommendation: settings o.k.


Was könnte dafür die Ursache sein?
Reiner.

DS_Starter

Hallo Reiner,

ein Wert (executing 17544 generated 1 errors) wollte oder will nicht in die DB.
Je nachdem ob es den Wert noch im cache gibt sieht man evtl. etwas mit verbose 5 im DbLog Device.


Grüße,
Heiko
ESXi@NUC+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter

reibuehl

Ich habe im Verbose 5 Log nichts weiter gefunden - es waren aber auch über 9 GB in 3 Stunden obwohl ich nur DBLog auf verbose 5 hatte.

Im Moment scheinen die Fehler aufgehört zu haben. Ich hatte sowohl MariaDB als auch FHEM ein paar mal neu gestartet.
Reiner.

DS_Starter

Jetzt ist der problematische Datensatz nicht mehr zu finden.
Sollte es wieder auftreten, dann setze verbose 5 im Device und sichere die Ausgaben ab "New database processing cycle" im Log für eine Analyse.

LG

 
ESXi@NUC+Debian+MariaDB, PV: SMA, Victron MPII+Pylontech+CerboGX
Maintainer: SSCam, SSChatBot, SSCal, SSFile, DbLog/DbRep, Log2Syslog, SolarForecast,Watches, Dashboard, PylonLowVoltage
Kaffeekasse: https://www.paypal.me/HMaaz
Contrib: https://svn.fhem.de/trac/browser/trunk/fhem/contrib/DS_Starter