Page 1 of 1

Re: domoticz, influxdb and grafana

Posted: Wednesday 15 February 2017 16:22
by mlamie
Can the wiki page be of any help?
https://www.domoticz.com/wiki/HttpLink

Re: domoticz, influxdb and grafana

Posted: Wednesday 15 February 2017 18:24
by hrikken
Use node-red and mqtt. Works perfect.


Verzonden vanaf mijn iPhone met Tapatalk Pro

Re: RE: Re: domoticz, influxdb and grafana

Posted: Wednesday 15 February 2017 20:02
by sincze
mlamie wrote:Can the wiki page be of any help?
https://www.domoticz.com/wiki/HttpLink
I also followed the wiki and had the same results. Image no data points

Sent from my SM-G925F using Tapatalk

Re: domoticz, influxdb and grafana

Posted: Thursday 16 February 2017 10:01
by fergalom
seems to be a new specific data push to InfluxDB in the latest betas - same location as the http / fibarolink data push

Re: domoticz, influxdb and grafana

Posted: Thursday 16 February 2017 17:46
by kiwi
Hum Influxdb is really pretty cool. Really I'd would like to have the option to send all data to InfluxDB instead of choosing all things, one per one... :/

Re: RE: Re: domoticz, influxdb and grafana

Posted: Saturday 18 February 2017 17:23
by sincze
sincze wrote:
mlamie wrote:Can the wiki page be of any help?
https://www.domoticz.com/wiki/HttpLink
I also followed the wiki and had the same results. Image no data points

Sent from my SM-G925F using Tapatalk
A finally:
http://localhost:8086/write?db=domoticz ... ecision=ms

Gives me results in influxdb no more nasty 400 error messages. :D
Grafana3.png
Grafana3.png (124.35 KiB) Viewed 5948 times
Grafana2.JPG
Grafana2.JPG (75.9 KiB) Viewed 5948 times

Re: domoticz, influxdb and grafana

Posted: Sunday 19 February 2017 8:49
by mlamie
sander815 wrote:yes, followed wiki also, no data point

but i think its because of the wrong date. I have no clue where the 1970 year comes from
I tried this weekend to setup InfluxDB via the Domoticz HTTP wiki page, it is a bit outdated but I did succeed. I used InfluxDB 1.2.
1) For example the the built-in web administration GUI is deprecated in InfluxDB 1.2 and is disabled by default. I used the CLI and works.
P.s. I found you can still use the administration GUI, you have to enable it in the influxdb.conf file

Code: Select all

[admin]
  # Determines whether the admin service is enabled.
enabled = true
2) The Domoticz setup details on the wiki page are for InfluxDB 0.8. At the bottom of the wiki page I found the url and data fields for InfluxDB 0.9 which also works for InfluxDB 1.2.

If I or someone else has time a wiki page update would be nice. Adding the screenshots from sincze could be usefull.

Regarding the incorrect date, on the InfluxDB website it is stated that InfluxDB uses the host’s local time in UTC to assign timestamps to data and for coordination purposes. So there is no need to search on InfluxDB time correction. You have to validate your host time configuration.

In case you use a Raspberry Pi use raspi-config.

What time and date is the host on?
If you use the command line interface and a Pi with Raspbian use:

Code: Select all

date --utc

Re: domoticz, influxdb and grafana

Posted: Sunday 19 February 2017 17:07
by sincze
Let me first build some more screens before starting at the wiki. :D
Grafana_OTGW.JPG
Grafana_OTGW.JPG (72.35 KiB) Viewed 5898 times

Re: domoticz, influxdb and grafana

Posted: Monday 06 March 2017 11:13
by Nhzz
I'm also playing with Grafana, already got some graphs in it. Real neat. :-)

What I am trying to do is to make the graph for cumulative usage start at zero for every time-interval I select.

Currently I have the following query for a single metric:

Code: Select all

SELECT mean("value") FROM "youless" WHERE $timeFilter GROUP BY time($interval) fill(null)
What I want is to subtract the lowest value from that interval, so it only counts the values from within that interval. That way the graph starts at zero and you know exactly what the usage is in that interval. To get the lowest value from that interval I use:

Code: Select all

SELECT min("value") FROM "youless" WHERE $timeFilter GROUP BY time($interval) fill(null)
So I thought combining those two (with subquery) like this should work:

Code: Select all

SELECT mean("value") - (SELECT min("value") FROM "youless" WHERE $timeFilter GROUP BY time($interval) fill(null)) FROM "youless" WHERE $timeFilter GROUP BY time($interval) fill(null)
Unfortunately this doesnt work. The query is not accepted as a subquery, although the query itself works just fine.

Anyone can give me a push in the right direction?

Re: domoticz, influxdb and grafana

Posted: Tuesday 04 April 2017 10:30
by Nhzz
No one? :idea: :oops:

Re: domoticz, influxdb and grafana

Posted: Wednesday 05 April 2017 22:03
by Trigun
sorry mate can't help you, whish I could.

is there perhaps a chance you can help me out?
I am looking all over the internet for a solution to put my smart meter data in Grafana.
I already have everything up and running, within domoticz it works perfectly but I can't seem to get it to work in Grafana.
I am using Grafana in combination with Influx.

Thanks in advance!

Re: domoticz, influxdb and grafana

Posted: Saturday 08 April 2017 23:11
by grubstake
There is a problem with the InfluxDB Data Push option, it correctly uploads all the device information but the date is not correctly being loaded in InfluxDB.

It appears to be something like the data push posting date/time with without declaring "precision". In any case, the date ends up being "null" which ends up starting with 1/1/1970.

See: https://github.com/influxdata/influxdb/issues/6041

Anyway, a query in the influxDB shell shows the least significant digits of time counting up from the time the data load was started on a new database, but the date is never correct:

Code: Select all

> select "value" from "Humidity"
name: Humidity
--------------
time				value
1970-01-01T00:00:00.024077824Z	32
1970-01-01T00:00:00.039430144Z	47
1970-01-01T00:00:00.046879232Z	33
1970-01-01T00:00:00.153165824Z	47
1970-01-01T00:00:00.376367104Z	32
1970-01-01T00:00:00.399168512Z	32
1970-01-01T00:00:00.671788544Z	32
1970-01-01T00:00:00.694589952Z	32
1970-01-01T00:00:00.944408576Z	32
1970-01-01T00:00:00.967209984Z	32
1970-01-01T00:00:01.239830016Z	32
1970-01-01T00:00:01.262631424Z	32
1970-01-01T00:00:01.296697856Z	32
1970-01-01T00:00:01.319499264Z	32
1970-01-01T00:00:01.592119296Z	32
1970-01-01T00:00:01.614920704Z	32
1970-01-01T00:00:01.62981888Z	47
1970-01-01T00:00:01.887540736Z	32
1970-01-01T00:00:01.910342144Z	33
It's not a problem with Grafana, its just that Grafana charts default to a time range that doesn't include timestamps way back in 1970.

Very frustrating.

Re: domoticz, influxdb and grafana

Posted: Saturday 24 June 2017 23:47
by hrikken
Trigun wrote:sorry mate can't help you, whish I could.

is there perhaps a chance you can help me out?
I am looking all over the internet for a solution to put my smart meter data in Grafana.
I already have everything up and running, within domoticz it works perfectly but I can't seem to get it to work in Grafana.
I am using Grafana in combination with Influx.

Thanks in advance!

I've used the combination Node-Red and MQTT (
mosquitto) where Domoticz pushes the data to the Misquitto broker and Node-Red pushes thes values to InfluDB. Node-red has all the necessary modules to do the job. It worksvery reliable too. I push all data that come from a smart meter every second to 2 InfluxDB servers simutaneously. Works flawless. Succes!



Verzonden vanaf mijn iPhone met Tapatalk Pro