Skip to content

Add recorder vars db_max_retries and db_retry_wait #12023

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

Merged
merged 4 commits into from
Feb 11, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions source/_integrations/recorder.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,16 @@ recorder:
description: The URL that points to your database.
required: false
type: string
db_max_retries:
description: The max amount of times, the recorder retries to connect to the database.
required: false
default: 10
type: integer
db_retry_wait:
description: The time in seconds, that the recorder sleeps when trying to connect to the database.
required: false
default: 3
type: integer
purge_keep_days:
description: Specify the number of history days to keep in recorder database after a purge.
required: false
Expand Down Expand Up @@ -180,6 +190,7 @@ If you are using the default `FULL` recovery model for MS SQL Server you will ne
### Database startup

If you are running a database server instance on the same server as Home Assistant then you must ensure that this service starts before Home Assistant. For a Linux instance running Systemd (Raspberry Pi, Debian, Ubuntu and others) then you should edit the service file.
To help facilitate this, db_max_retry and db_retry_wait variables have been added to ensure the recorder retries the connection to your database enough times, for your database to start up.

```bash
sudo nano /etc/systemd/system/home-assistant@homeassistant.service
Expand Down