My guide to grafana / influxdb: Difference between revisions

From Edgar BV Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
[http://codersaur.com/2016/04/smartthings-data-visualisation-using-influxdb-and-grafana/ adapted from SmartThings Data Visualisation using InfluxDB and Grafana]
[http://codersaur.com/2016/04/smartthings-data-visualisation-using-influxdb-and-grafana/ adapted from SmartThings Data Visualisation using InfluxDB and Grafana]


=Influxdb=
<pre>
<pre>
apt-get install influxdb influxdb-cli influxdb-client
apt-get install influxdb influxdb-cli influxdb-client
Line 18: Line 19:
</pre>
</pre>


=Grafana=
[https://grafana.com/grafana/download?platform=linux The Grafana download page]
[https://grafana.com/grafana/download?platform=linux The Grafana download page]
[https://grafana.com/docs/installation/debian/ debian installation page for grafana]
[https://grafana.com/docs/installation/debian/ debian installation page for grafana]
<pre>
<pre>
cd /usr/local/src/
apt-get install libfontconfig1 apt-transport-https
wget https://dl.grafana.com/oss/release/grafana_6.1.6_amd64.deb
</pre>
apt-get install libfontconfig1
vi /etc/apt/sources.list
dpkg -i grafana_6.1.6_amd64.deb
<pre>
deb https://packages.grafana.com/oss/deb stable main
</pre>
now you can install
<pre>
dselect update
apt-get install grafana
systemctl daemon-reload
systemctl daemon-reload
systemctl enable grafana-server
systemctl enable grafana-server
Line 38: Line 46:


change password
change password
</pre>
vi /etc/apt/sources.list
<pre>
deb https://packages.grafana.com/oss/deb stable main
</pre>
then you need to add the https transport before updating
<pre>
apt-get install apt-transport-https
dselect update
</pre>


vi /etc/grafana/grafana.ini
vi /etc/grafana/grafana.ini
Line 54: Line 51:
;allow_sign_up = false
;allow_sign_up = false
</pre>
</pre>
Now you can add a data source, which is an influxdb, with name set to Honeywell, URL set to http://db-01.edgarbv.int:8086/ and Influxdb database name, user and password filled in. You can then save and test.
NOTE the URL for data access is port 8086!

Revision as of 10:57, 13 May 2019

adapted from SmartThings Data Visualisation using InfluxDB and Grafana

Influxdb

apt-get install influxdb influxdb-cli influxdb-client
service influxdb start
systemctl enable influxdb
influx

you can also surf to http://db-01.edgarbv.int:8083/ to check if it works

Back in the cli (influx) enter <jpre> Visit https://enterprise.influxdata.com to register for updates, InfluxDB server management, and monitoring. Connected to http://localhost:8086 version 1.0.2 InfluxDB shell version: 1.0.2 > create database "honeywell" > create user "grafana" with password 'password'

Grafana

The Grafana download page debian installation page for grafana

apt-get install libfontconfig1 apt-transport-https

vi /etc/apt/sources.list

deb https://packages.grafana.com/oss/deb stable main

now you can install

dselect update
apt-get install grafana
systemctl daemon-reload
systemctl enable grafana-server
mv /var/lib/grafana/ /home/
ln -s /home/grafana /var/lib/grafana
systemctl start grafana-server

Verify it works by visiting

http://monitor.edgarbv.int:3000

admin / admin

change password

vi /etc/grafana/grafana.ini
<pre>
;allow_sign_up = false

Now you can add a data source, which is an influxdb, with name set to Honeywell, URL set to http://db-01.edgarbv.int:8086/ and Influxdb database name, user and password filled in. You can then save and test.

NOTE the URL for data access is port 8086!