DCI last values don't store history data

Started by xelander, July 29, 2020, 11:51:47 AM

Previous topic - Next topic

xelander

Hello,
I'm new to NetXMS, I just installed it on a CentOS 8 VM with MariaDB 10.3.17 and it's working fine, but there is one thing I cannot understand.

I configured an internal DCI (ICMP.ResponseTime.Max) and an SNMP DCI (.1.3.6.1.2.1.2.2.1.11.1 - ifInUcastPkts) and they seem to work fine, since I can see the last values.
But when I try to see the History or a Chart for a value they are both empty (see attachments).

Can you help me? Am I doing something wrong?

Thanks,
Alessandro

Victor Kirhenshtein

Hi,

could be database issue or time zone issue. In database you should have table idata_nnn, where nnn is actual node object ID. Check if you have any records in that table. If yes, check that time on your server is correct and that time zone is correct as well. Internally server and client uses UTC timestamps, so even when time looks identical it may in fact be incorrect on one side when concerted to UTC. If there are no records in idata table then likely there is issue with storing data to database - in that case check server log for SQL errors.

Best regards,
Victor

xelander

Hi,
thank you very much for your answer, I checked the DB and the data seems to be there (see screeshots).

Timestamps seem correct too: in the table they're UTC and on the server and client the time is CEST (UTC+1, +2 with daylight savings).
Even if they were wrong, shouldn't I at least see the values in the "History" view, albeit with wrong timestamps?

Thanks,
Alessandro

Filipp Sudanov

This looks to be very strange. I would suggest to turn on debugging from the database side to see what exactly queries are generated when you request history / graph from the front-end. And then checking if such a query really returns any data.
Also, if it's fine for you to recreate the database you can try to move to Postgres - it's generally more tested because more netxms users are using it.

Filipp Sudanov

Also - 3.4.284 is now available, it has a fix for one error that was also related to not displaying historic data, could be that it's the same error here. Please try this new version.

xelander

Hello,
I enabled query logging on the DB and the query seems to be correct, and it returns valid data (see attachements):

SELECT idata_timestamp,idata_value,raw_value FROM idata_2069 WHERE item_id=682 ORDER BY idata_timestamp DESC LIMIT 4096

I'll try the new version as soon as possible, and I'll let you know.

Thanks,
Alessandro


xelander

Hi,
I upgraded to version 3.4.284, both the server and the management console, but unfortunately nothing changed.

The query is the same:
SELECT idata_timestamp,idata_value,raw_value FROM idata_2069 WHERE item_id=682 ORDER BY idata_timestamp DESC LIMIT 4096
but still no data is displayed in the History view or in the Charts view, and I cannot find any error in MariaDB nor Netxms logs.

Is there anything alse I can try to debug the problem?

Thanks,
Alessandro


Victor Kirhenshtein

Try to change DCI data type to "String" and request history - will it show something?

Best regards,
Victor

xelander

Nothing changed, sorry  :'(




Filipp Sudanov

How did you compile netxms - can you show config.log file? Can you show the output of yum list installed

xelander

Hi,I followed the directions on the "NetXMS Administrator Guide, Release 3.4.178", chapter "3.6  Installing from sources", that is:
# ./configure --with-server --with-mysql --with-agent
# make
# make install

I'm attaching the config.log and the output of yum list installed.If you need anything else, please let me know.

Thank you,Alessandro


Filipp Sudanov

As an experiment - can you try to a different configure command:

./configure prefix=/opt/netxms-master --with-server --with-mariadb --with-mariadb-compat-headers --with-agent

xelander

I tried (see attached config.log), but the issue is still present.
The query is the same as before:200806 15:54:06    266 Prepare  SELECT idata_timestamp,idata_value,raw_value FROM idata_2069 WHERE item_id=? ORDER BY idata_timestamp DESC LIMIT 4096
                   266 Execute  SELECT idata_timestamp,idata_value,raw_value FROM idata_2069 WHERE item_id=683 ORDER BY idata_timestamp DESC LIMIT 4096
                   266 Close stmt

I was wondering if it could be a client issue, instead of a server one.
After all, if the server had a problem SELECT'ing data from the DB, almost nothing would work...


Filipp Sudanov

What's the operating system where the client is running? What's client version? Is it downloaded from netxms web site?
For testing - may be you could try the client on another machine, preferrably on a different OS.

xelander

I tried the Windows client (nxmc-3.4.284-win32-x64.zip) both on Windows 7 and on Windows 10, but I also tried the web interface (nxmc-3.4.284.war), everything downloaded from the netxms website, so it seems the issue doesn't depend on the client OS.
I still have to try on Linux...