# Influxdb + Telegraf + Grafana

**URL:** https://community.influxdata.com/t/influxdb-telegraf-grafana/11279
**Category:** Systems
**Created:** [September 18, 2019, 9:33am UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279 "2019-09-18T09:33:55Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![G0nz0uk](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/g0nz0uk/32/3554_2.png) [@G0nz0uk](https://community.influxdata.com/u/G0nz0uk)
#### Post date: [September 18, 2019, 9:33am UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/1 "2019-09-18T09:33:55Z")

</div>

Hello,

I’m currently using Prometheus with Grafana to capture server metrics and display on a nice Grafana Dashboard. However some dashboards you can import are built round Influxdb and Telegraf.

So I’ve installed Influx DB and then installed the Telegraf agent on a couple of VMs and the data is not being pulled into Grafana, all I see is the server name.

How can I check if the InfluxDB is receiving the data from the 2 servers?

Telegraf log file:

```
2019-09-18T09:41:00Z D! [outputs.influxdb] Wrote batch of 17 metrics in 27.28973ms
2019-09-18T09:41:00Z D! [outputs.influxdb] Buffer fullness: 6 / 10000 metrics
2019-09-18T09:41:04Z D! [agent] Stopping service inputs
2019-09-18T09:41:04Z D! [agent] Input channel closed
2019-09-18T09:41:04Z I! [agent] Hang on, flushing any cached metrics before shutdown
2019-09-18T09:41:04Z D! [outputs.influxdb] Wrote batch of 6 metrics in 1.72249ms
2019-09-18T09:41:04Z D! [outputs.influxdb] Buffer fullness: 0 / 10000 metrics
2019-09-18T09:41:04Z D! [agent] Closing outputs
2019-09-18T09:41:04Z D! [agent] Stopped Successfully

```

Thanks

---

<div class="post-metadata">

### Author: ![daniel](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/daniel/32/142_2.png) [@daniel](https://community.influxdata.com/u/daniel)
#### Post date: [September 19, 2019, 9:10pm UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/2 "2019-09-19T21:10:26Z")

</div>

Looks like at least some data is being written successfully.

You can explore the data in Grafana just by creating a new panel and editing the query, at a bare minimum you need to click on `measurement` and `field(value)` and select one of the choices.

Another option is to use the `influx` command to take a look from a terminal:

```auto
$ influx
Connected to http://localhost:8086 version 1.7.8
InfluxDB shell version: 1.7.8
> use telegraf
Using database telegraf
> show measurements
name: measurements
name
----
cpu
> select * from cpu where time > now() - 1m;

```

---

<div class="post-metadata">

### Author: ![G0nz0uk](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/g0nz0uk/32/3554_2.png) [@G0nz0uk](https://community.influxdata.com/u/G0nz0uk)
#### Post date: [September 21, 2019, 3:26pm UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/3 "2019-09-21T15:26:18Z")

</div>

Measurements are coming through to Influx, I just get get Grafana to show them:

```
1569078730000000000 cpu-total svr-confluence 0 0 99.24736578011152 0.05017561465144254 0 0 0.050175614651469275 0 0.3010536879083878 0.35122930256092666
1569078730000000000 cpu0 svr-confluence 0 0 99.39698492464723 0 0 0 0.10050251256267649 0 0.20100502512521015 0.30150753768781524
1569078730000000000 cpu1 svr-confluence 0 0 99.19759277875312 0.10030090270840554 0 0 0 0 0.4012036108343972 0.3009027081249427
>
>
>
>
> show measurements
name: measurements
name
----
cpu
disk
diskio
kernel
mem
processes
swap
system
>

```

Lists in Grafana

 ![image](https://us1.discourse-cdn.com/flex023/uploads/influxdata/original/2X/8/89e5137bcd66c4071c54635a55962cb78d8feffa.png)

I just can’t seem to get the metrics displayed, using any query.

---

<div class="post-metadata">

### Author: ![daniel](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/daniel/32/142_2.png) [@daniel](https://community.influxdata.com/u/daniel)
#### Post date: [September 26, 2019, 2:07am UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/4 "2019-09-26T02:07:02Z")

</div>

Pick `cpu` and then on the SELECT line click on `value` in the `field(value)` box, there should be another dropdown with the available field names. After you pick one I believe at that point you should see some data.

---

<div class="post-metadata">

### Author: ![got2boll](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/got2boll/32/3982_2.png) [@got2boll](https://community.influxdata.com/u/got2boll)
#### Post date: [December 1, 2019, 9:26pm UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/5 "2019-12-01T21:26:31Z")

</div>

Hello guys,  
I have similar insallation but when I use “show measurements” function in the terminal I have no response.  
Here is the result, does it mean no data is registered in the database ?

> SHOW MEASUREMENTS  
> SHOW MEASUREMENTS

Here is the log of telegraf:  
2019-11-29T22:11:00Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]  
2019-11-29T22:33:16Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]  
2019-11-29T22:34:57Z I! Loaded inputs: mqtt\_consumer  
2019-11-29T22:34:57Z I! Loaded aggregators:  
2019-11-29T22:34:57Z I! Loaded processors:  
2019-11-29T22:34:57Z I! Loaded outputs: influxdb  
2019-11-29T22:34:57Z I! Tags enabled: host=VM-BrokerABBFR  
2019-11-29T22:34:57Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“VM-BrokerABBFR”, Flush Interval:10s  
2019-11-29T22:34:57Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]  
2019-12-01T00:02:26Z I! [agent] Hang on, flushing any cached metrics before shutdown  
2019-12-01T00:03:24Z I! Loaded inputs: mqtt\_consumer  
2019-12-01T00:03:24Z I! Loaded aggregators:  
2019-12-01T00:03:24Z I! Loaded processors:  
2019-12-01T00:03:24Z I! Loaded outputs: influxdb  
2019-12-01T00:03:24Z I! Tags enabled: host=VM-BrokerABBFR  
2019-12-01T00:03:24Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“VM-BrokerABBFR”, Flush Interval:10s  
2019-12-01T00:03:24Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]  
2019-12-01T21:09:45Z I! [agent] Hang on, flushing any cached metrics before shutdown  
2019-12-01T21:09:51Z I! Loaded inputs: mqtt\_consumer  
2019-12-01T21:09:51Z I! Loaded aggregators:  
2019-12-01T21:09:51Z I! Loaded processors:  
2019-12-01T21:09:51Z I! Loaded outputs: influxdb  
2019-12-01T21:09:51Z I! Tags enabled: host=VM-BrokerABBFR  
2019-12-01T21:09:51Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“VM-BrokerABBFR”, Flush Interval:10s  
2019-12-01T21:09:51Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]  
2019-12-01T21:13:46Z I! [agent] Hang on, flushing any cached metrics before shutdown  
2019-12-01T21:13:49Z I! Loaded inputs: mqtt\_consumer  
2019-12-01T21:13:49Z I! Loaded aggregators:  
2019-12-01T21:13:49Z I! Loaded processors:  
2019-12-01T21:13:49Z I! Loaded outputs: influxdb  
2019-12-01T21:13:49Z I! Tags enabled: host=VM-BrokerABBFR  
2019-12-01T21:13:49Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“VM-BrokerABBFR”, Flush Interval:10s  
2019-12-01T21:13:49Z I! [inputs.mqtt\_consumer] Connected [tcp://127.0.0.1:1883]

---

<div class="post-metadata">

### Author: ![daniel](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/daniel/32/142_2.png) [@daniel](https://community.influxdata.com/u/daniel)
#### Post date: [December 4, 2019, 9:18pm UTC](https://community.influxdata.com/t/influxdb-telegraf-grafana/11279/6 "2019-12-04T21:18:14Z")

</div>

Doesn’t look like anything is being collected, if you run Telegraf with `--debug` it will log how many metrics are sent. I also recommend enabling the `internal` input plugin, which will send metrics about Telegraf activity to InfluxDB.
