InfluxDB errors by default

Bug #1619620 reported by Stuart Bishop
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Telegraf Charm
Invalid
High
Peter Sabaini

Bug Description

I'm seeing this in the logs of a deploy without influxdb:

2016/09/02 11:15:20 Database creation failed: Get http://localhost:8086/query?db=&q=CREATE+DATABASE+IF+NOT+EXISTS+%22telegraf%22: dial tcp 127.0.0.1:8086: getsockopt: connection refused

Looks like something is enabled by default that shouldn't be?

Revision history for this message
Wouter van Bommel (woutervb) wrote :

The code assumes indeed that an influxdb is always available as output, while it should be optional, and the config part should only be written if the relation is actually established.

Other outputs are supported via yaml config option(s)

Changed in charm-telegraf:
importance: Undecided → High
status: New → Confirmed
Changed in charm-telegraf:
assignee: nobody → Peter Sabaini (peter-sabaini)
Revision history for this message
Peter Sabaini (peter-sabaini) wrote :

The [[outputs.influxdb]] config originates from the telegraf package itself. Telegraf is being started with default config on first install, and with the default config present will log the above error.

Later on the charm reconfigures telegraf, and does the right thing:

It removes the outputs.influxdb stanza, and will only add it @when('influxdb-api.available'). Further restarts without influxdb-api.available won't produce the "connection refused" message above.

Arguably this bug should be repointed to the telegraf package for starting telegraf with an overly optimistic default config.

I will close it as invalid for the charm though.

Changed in charm-telegraf:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.