Problem to store Last values into database.
-
I upgraded my Slackware installation from 14.2 to the latest and NetXMS from 2.0.7 to 2.2.7. During the upgrade I had to delete netxms database: DROP DATABASE netxms; . I compiled NetXMS from source with following options: ./configure --with-server --with-agent --with-snmp --with-mariadb --disable-mqtt --disable-ipv6.
After I created the new database, NetXMS started correctly, but not saving any real data from "Last values". It stores values with 01.01.1970 01:00:00 Time Stamp and 0 Value.There are no errors reported in MariaDB and NetXMS logfiles. MariaDB version is: 10.3.8.
Can somebody help me, what to check, please?
-
The strange thing is, when I do a query with mysql CLI from database, for examle: SELECT idata_timestamp,idata_value FROM netxms.idata_114 WHERE item_id = 109; I can see the correct values with timestamp. Do not know how to translate idata_timestamp to real date and time yet, but idata_value is correct.
It looks like, the data stored correcly in the database, just the NetXms client (PC and Mobile) cannot display it.
Thanks.
-
Hi,
it's problem with reading data from database, not with storing. It is caused by bug in MariaDB client library https://jira.mariadb.org/browse/CONC-281. It is supposed to be fixed in latest client version, but could be not. Our MariaDB driver has check for client version that activates workaround - maybe it erroneously assumes version number where this issue was fixed. You can try to find the following lines in src/db/dbdrv/mariadb/mariadb.cpp:
/* workaround for MariaDB C Connector bug CONC-281 */ if (mysql_get_client_version() < 100209) // for any client before 10.2.9 { mysql_stmt_store_result(hStmt->statement); }and comment out version check so it will look like this:
/* workaround for MariaDB C Connector bug CONC-281 */ //if (mysql_get_client_version() < 100209) // for any client before 10.2.9 { mysql_stmt_store_result(hStmt->statement); }then recompile MariaDB driver.
Best regards,
Victor -
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login