Hi all,
I tried without success to setup MariaDB as my db for HA.
This is what I’ve done (using this link):
Create a DB in MARIADB using console:
mysql -u root -p
CREATE DATABASE home_assistant;
CREATE USER ‘hass_user’ IDENTIFIED BY ‘xxxxxxxxxxxx’;
GRANT ALL PRIVILEGES ON home_assistant. TO ‘hass_user’@‘localhost’ IDENTIFIED BY ‘xxxxxxxxxxxxxx’;*
FLUSH PRIVILEGES;
exit
then added this in config:
recorder:
purge_interval: 1
db_url: !secret recorder_db_url
purge_keep_days: 7
include:
domains:
- sensor
- climate
- binary_sensor
- light
- timer
# entities:
# - sensor.consumo
exclude:
domains:
- automation
- script
where recorder_db_url is this:
recorder_db_url: ‘mysql://hass_user:[email protected]:3306/home_assistant?charset=utf8’
I checked for validation and reboot.
Record and other components (history, logbook) are no longer working.
This is the error in log:
Error during connection setup: (MySQLdb._exceptions.OperationalError) (1044, “Access denied for user ‘hass_user’@‘%’ to database ‘home_assistant’”) (Background on this error at: Error Messages — SQLAlchemy 2.0 Documentation) (retrying in 3 seconds)
Can someone please help me?
Thank you in advance!