Grafana datasource problem - only for DCIs

Started by JayST, September 18, 2019, 05:50:33 PM

Previous topic - Next topic

JayST

I'm using NetXMS v3 and Grafana 6.3.x and succesfully deployed the NetXMS datasource on grafana. It connects to the webapi and is able to show alarms.
However, DCIs do not show points on the graph. I can select the DCIs but grafana is not able to pull points for the DCI.
The grafana query to the API returns error 46.

below is the query inspector result from grafana.
i found the following wiki page, and statement about java.xml.bind module.
However, i'm on ubuntu 18.04 , tomcat9 and java 11

any idea what's wrong? Connectivity and authentication seems right because i do get to see alarms in a grafana table just fine.

java -version
openjdk version "11.0.4" 2019-07-16
OpenJDK Runtime Environment (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3)
OpenJDK 64-Bit Server VM (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3, mixed mode, sharing)


"If curl test works but grafana returns "Internal error" ({"description":"Internal error","error":46}")
Add "--add-modules java.xml.bind" to JAVA_OPTS in /etc/default/tomcat8 "


https://wiki.netxms.org/wiki/Web_service_API




Object
xhrStatus:"complete"
request:Object
method:"GET"
url:"api/datasources/proxy/20/grafana/datacollection"
data:null
params:Object
interval:200
from:_
to:_
targets:"[{"dci":{"id":"945","name":"Inbound traffic on NET_STOR (bits/sec)"},"dciTarget":{"id":"3370","name":"host01.corp.local"},"legend":"","refId":"A","type":"DCI","datasource":"NetXMS"},{"dci":{"id":"946","name":"Outbound traffic on NET_STOR (bits/sec)"},"dciTarget":{"id":"3370","name":"host01.corp.local"},"legend":"","refId":"B","type":"DCI","datasource":"NetXMS"}]"
response:Object
description:"'java.util.Iterator org.json.JSONArray.iterator()'"
error:46

JayST

ok i just saw a new netxms build and i upgraded the server to 3.0.2284 and web service API using netxms-websvc-3.0.2284.war
after that, DCI values showed up within grafana graphs. No error 46 anymore.

Not sure what the fix was, but hey, it works. Happy ;D