FHEM Forum

FHEM => Automatisierung => Thema gestartet von: cruser1800 am 20 Juli 2025, 19:04:39

Titel: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: cruser1800 am 20 Juli 2025, 19:04:39
Hallo,

ich habe bei DBLog festgestellt, dass der Text beim Feld EVENT auf (64) beschränkt ist, obwohl in der Config und in der Datenbank die Feldgröße (512) eingestellt ist.

Weiterhin würde ich gern die Reading auch auf (128) erweitern. Die Datenbank habe ich angepasst. In FHEM / DBLog finde ich keine Möglichkeit es einzustellen.

Ich habe jetzt versucht in der 93_DBLog.pm testweise den Wert auf (128) zu erhöhen. Bringt leider auch nach einem Neustart von FHEM kein Erfolg. Es wird jetzt zwar bei COLUMNS für READING (128) angezeigt, aber die Werte werden trotzdem abgeschnitten.

Kann mir jemand einen Tipp geben?

Danke Lutz
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: DS_Starter am 20 Juli 2025, 19:27:27
Hallo Lutz,

Zitatich habe bei DBLog festgestellt, dass der Text beim Feld EVENT auf (64) beschränkt ist, obwohl in der Config und in der Datenbank die Feldgröße (512) eingestellt ist.
Dann führe mal den configCheck aus.

ZitatWeiterhin würde ich gern die Reading auch auf (128) erweitern. Die Datenbank habe ich angepasst. In FHEM / DBLog finde ich keine Möglichkeit es einzustellen.
Es gibt dafür das Attribut colReading.

LG,
Heiko
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: cruser1800 am 20 Juli 2025, 20:00:09
Danke für die schnelle Antwort.

Beim configCheck ist bei beiden der Wert (512). In der Datenbank wird bei ca. 64 abgeschnitten.

Result of table 'history' check

Column width set in table history: 'DEVICE' = 64, 'TYPE' = 64, 'EVENT' = 512, 'READING' = 128, '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.


Das Attribut colReading habe ich auf 128 umgestellt.

Leider wird immer noch abgeschnitten.


Event
MQTT2_Shelly_Waschmaschiene_rpc_params_switch_0_ae...
Reading
MQTT2_Shelly_Waschmaschiene_rpc_params_switch_0_ae...

Muss ich noch neu starten?
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: DS_Starter am 20 Juli 2025, 21:02:23
Restart schadet nicht, sollte aber auch so gehen.

Wenn es weiterhin nicht so funktioniert wie erwartet, verbose 4 im Device einstellen und Log auswerten. Verbose 5 als weitere Steigerung. Weiterhin configCheck komplett posten und nicht nur ein Stückchen.

LG
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: cruser1800 am 20 Juli 2025, 21:21:44
Hallo Heiko,

hier der congfigCHeck komplett. Verbose 4 muss ich noch auswerten

Available Drivers in your system

DBD::DBM, DBD::ExampleP, DBD::File, DBD::Gofer, DBD::MariaDB, 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.11.0
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=DBLog;host=localhost;port=3307, User -> fhemuser, Password -> read o.k.
Rating:

Result of connection check

Connection to database DBLog successfully done.
The time required to establish the connection was 0.0028 seconds.
Communication Compression between Client and Server: off
Rating:
Recommendation: settings o.k.

Result of Character Sets and Collation check

Character Set used by Client (connection): LATIN1
Collation used by Client (connection): LATIN1_SWEDISH_CI
Character Set used by DB DBLog: LATIN1
Collation used by DB DBLog: LATIN1_SWEDISH_CI
Rating:
Recommendation: The Character Set of the database should be changed to 'utf8mb4' so that umlauts and all special characters can be stored.
You can easy do that with the DbRep command set <DbRep-Device> migrateCollation utf8mb4_bin.
Then customize the use of UTF8 connections by setting the UTF8 parameter in the file './db.conf'.


Result of insert mode check

Insert mode of DbLog-device logdb is: Sequential
Rating:
Recommendation: Setting attribute "insertMode" to "0" (or delete it) may result a higher write performance in most cases. Feel free to try this mode.

Result of plot generation method check

WARNING - at least one of your FHEMWEB devices has attribute 'plotEmbed' not set.

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

Rating:
Recommendation: You should set attribute 'plotEmbed = (1 | 2)' in relevant devices. If this attribute is not set, blocking situations may occure when creating plots.
Refer to plotEmbed for further information.


Result of table 'history' check

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

Result of table 'current' check
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: cruser1800 am 20 Juli 2025, 21:36:17
Hallo Heiko,

Danke für die Hilfe. Mit Verbose 4 habe ich gesehen, dass DBLog alles richtig macht! Nur PHPMyAdmin stellt aus irgendeinem Grund die Daten nicht dar!

Nach dem Export von Probedaten, war alles enthalten!

Ich suche jetzt dort weiter.

Danke Lutz
Titel: Aw: DBLog - Feldgröße - Text Event wird abgeschnitten
Beitrag von: DS_Starter am 20 Juli 2025, 21:37:11
Character Set used by Client (connection): LATIN1
Collation used by Client (connection): LATIN1_SWEDISH_CI
Character Set used by DB DBLog: LATIN1
Collation used by DB DBLog: LATIN1_SWEDISH_CI
Rating:
Recommendation: The Character Set of the database should be changed to 'utf8mb4' so that umlauts and all special characters can be stored.
You can easy do that with the DbRep command set <DbRep-Device> migrateCollation utf8mb4_bin.
Then customize the use of UTF8 connections by setting the UTF8 parameter in the file './db.conf'.
Möglicherweise auch ein To Do um Längen des zu speichernden Strings richtig bestimmen zu können.

Das Log wird sicherlich noch weitere Infos geben was eigentlich passiert.

(Hat sich überschnitten...)