SQL Sensor Errors with MariaDB
The problem
I have more than 60 sql sensors configured with the standard sql integrations connected to a MariaDB running locally. After upgrade to 2024.3.0 most of them have become unvailable right from the startup in a random way. Sometimes reloading helps, sometimes not. Reverted back to 2024.2.5 and everything is fine again.
So obviuosly something is not running smoth with db connections in this release.
What version of Home Assistant Core has the issue?
2024.3.0
What was the last working version of Home Assistant Core?
2024.2.5
What type of installation are you running?
Home Assistant OS
Integration causing the issue
SQL
Link to integration documentation on our website
No response
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Error executing query xxx: (MySQLdb.OperationalError) (1040, 'Too many connections') (Background on this error at: https://sqlalche.me/e/20/e3q8)
Additional information
No response
Hey there @gjohansson-st, @dougiteixeira, mind taking a look at this issue as it has been labeled with an integration (sql) you are listed as a code owner for? Thanks!
Code owner commands
Code owners of sql can trigger bot actions by commenting:
@home-assistant closeCloses the issue.@home-assistant rename Awesome new titleRenames the issue.@home-assistant reopenReopen the issue.@home-assistant unassign sqlRemoves the current integration label and assignees on the issue, add the integration domain after the command.@home-assistant add-label needs-more-informationAdd a label (needs-more-information, problem in dependency, problem in custom component) to the issue.@home-assistant remove-label needs-more-informationRemove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.
(message by CodeOwnersMention)
sql documentation sql source (message by IssueLinks)
Is the MariaDB the add on or something you are running yourself?
Is the official MariaDB addon
I have a similar issue. I set up a sensor that should report the DB size. This is not updated at all.
Couldn't connect using mysql://:@core-mariadb/homeassistant?charset=utf8 DB_URL: (MySQLdb.OperationalError) (2002, "Can't connect to server on 'core-mariadb' (115)") (Background on this error at: https://sqlalche.me/e/20/e3q8)
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 has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.