Hi, I’ve been trying to upgrade to 2024.4.3 but every time I do this I get issues with recorder. Luckily I have been able to revert to the previous version without issue.
I think I can see a message about mariadb in the logs, and also something about history (although that might depend on recorder). I attach a section of my log at the bottom of this message. Has anyone had similar issue or is there a known fix?
Regards,
Martin
MySQLdb.OperationalError: (2005, “Unknown server host ‘core-mariadb’ (-5)”)
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/components/recorder/core.py”, line 940, in _setup_recorder
self._setup_connection()
File “/usr/src/homeassistant/homeassistant/components/recorder/core.py”, line 1443, in _setup_connection
Base.metadata.create_all(self.engine)
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/sql/schema.py”, line 5825, in create_all
bind._run_ddl_visitor(
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 3254, in _run_ddl_visitor
with self.begin() as conn:
File “/usr/local/lib/python3.12/contextlib.py”, line 137, in enter
return next(self.gen)
^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 3244, in begin
with self.connect() as conn:
^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 3280, in connect
return self._connection_cls(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 148, in init
Connection._handle_dbapi_exception_noconnection(
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 2444, in _handle_dbapi_exception_noconnection
raise sqlalchemy_exception.with_traceback(exc_info[2]) from e
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 146, in init
self._dbapi_connection = engine.raw_connection()
^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/base.py”, line 3304, in raw_connection
return self.pool.connect()
^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 449, in connect
return _ConnectionFairy._checkout(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 1263, in _checkout
fairy = _ConnectionRecord.checkout(pool)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 712, in checkout
rec = pool._do_get()
^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/impl.py”, line 179, in _do_get
with util.safe_reraise():
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/util/langhelpers.py”, line 146, in exit
raise exc_value.with_traceback(exc_tb)
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/impl.py”, line 177, in _do_get
return self._create_connection()
^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 390, in _create_connection
return _ConnectionRecord(self)
^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 674, in init
self.__connect()
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 900, in __connect
with util.safe_reraise():
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/util/langhelpers.py”, line 146, in exit
raise exc_value.with_traceback(exc_tb)
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/pool/base.py”, line 896, in __connect
self.dbapi_connection = connection = pool._invoke_creator(self)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/create.py”, line 643, in connect
*return dialect.connect(*cargs, *cparams)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/sqlalchemy/engine/default.py”, line 617, in connect
*return self.loaded_dbapi.connect(*cargs, *cparams)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/MySQLdb/init.py”, line 121, in Connect
*return Connection(*args, *kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.12/site-packages/MySQLdb/connections.py”, line 195, in init
*super().init(*args, *kwargs2)
sqlalchemy.exc.OperationalError: (MySQLdb.OperationalError) (2005, “Unknown server host ‘core-mariadb’ (-5)”)
(Background on this error at: Error Messages — SQLAlchemy 2.0 Documentation)
2024-04-21 15:28:58.570 ERROR (MainThread) [homeassistant.setup] Setup failed for ‘recorder’: Integration failed to initialize.
2024-04-21 15:29:02.157 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of ‘history’. Setup failed for dependencies: [‘recorder’]
2024-04-21 15:29:02.158 ERROR (MainThread) [homeassistant.setup] Setup failed for ‘history’: Could not setup dependencies: recorder
2024-04-21 15:29:02.166 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of ‘energy’. Setup failed for dependencies: [‘history’, ‘recorder’]