Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HA does not reconnect to influxdb when server goes down #25038

Closed
rsimiciuc opened this issue Jul 9, 2019 · 4 comments
Closed

HA does not reconnect to influxdb when server goes down #25038

rsimiciuc opened this issue Jul 9, 2019 · 4 comments

Comments

@rsimiciuc
Copy link

Home Assistant release with the issue:
0.95.4

Operating environment (Hass.io/Docker/Windows/etc.):
Docker

Component/platform:
influxdb

Description of problem:
If influxdb server goes down, HA will trigger a notification that lost connection to influxdb, but it will not try to reconnect if influxdb comes back up.

@amelchio
Copy link
Contributor

What does that notification look like?

@ghost
Copy link

ghost commented Jul 15, 2019

Hey there @fabaff, mind taking a look at this issue as its been labeled with a integration (influxdb) you are listed as a codeowner for? Thanks!

This is a automatic comment generated by codeowners-mention to help ensure issues and pull requests are seen by the right people.

@tribut
Copy link
Contributor

tribut commented Sep 27, 2019

The error I'm getting when influxdb shuts down:

Exception in thread InfluxDB:
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/threading.py", line 926, in _bootstrap_inner
    self.run()
  File "/usr/src/homeassistant/homeassistant/components/influxdb/__init__.py", line 369, in run
    self.write_to_influxdb(json)
  File "/usr/src/homeassistant/homeassistant/components/influxdb/__init__.py", line 348, in write_to_influxdb
    self.influx.write_points(json)
  File "/usr/local/lib/python3.7/site-packages/influxdb/client.py", line 490, in write_points
    tags=tags, protocol=protocol)
  File "/usr/local/lib/python3.7/site-packages/influxdb/client.py", line 551, in _write_points
    protocol=protocol
  File "/usr/local/lib/python3.7/site-packages/influxdb/client.py", line 327, in write
    headers=headers
  File "/usr/local/lib/python3.7/site-packages/influxdb/client.py", line 282, in request
    raise InfluxDBServerError(response.content)
influxdb.exceptions.InfluxDBServerError: b'{"error":"write failed"}\n'

There are no further messages regarding influxdb and it only recovers when HA is restarted.

Edit: Might have been caused by an older influxdb version? I upgraded to Debian buster (influxdb 1.6.4) and now I no longer get this message and HA reconnects when influxdb is back...

@stale
Copy link

stale bot commented Dec 30, 2019

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue now has been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 30, 2019
@stale stale bot closed this as completed Jan 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants