The backup procedure on ubuntu does not work. Tried zed with the same problem
**Environment**:
* OS Ubuntu 22.04
* Kolla-Ansible version stable/zed
* globals.yml
enable_proxysql: "yes"
enable_mariabackup: "yes"
Running kolla-ansible -i /etc/kolla/inventory mariadb_backup
output is:
fatal: [ctrl-01]: FAILED! => {"changed": true, "msg": "Container exited with non-zero return code 1", "rc": 1, "stderr": "INFO:__main__:Loading config file at /var/lib/kolla/config_files/config.json\nINFO:__main__:Validating config file\nINFO:__main__:Kolla config strategy set to: COPY_ALWAYS\nINFO:__main__:Copying service configuration files\nINFO:__main__:Deleting /etc/mysql/my.cnf\nINFO:__main__:Copying /var/lib/kolla/config_files/my.cnf to /etc/mysql/my.cnf\nINFO:__main__:Setting permission for /etc/mysql/my.cnf\nINFO:__main__:Writing out command to execute\nINFO:__main__:Setting permission for /var/log/kolla/mariadb\nINFO:__main__:Setting permission for /backup\n[00] 2023-10-31 11:50:23 Connecting to MariaDB server host: 10.224.133.131, user: backup_shard_0, password: set, port: 3306, socket: not set\n[00] FATAL ERROR: 2023-10-31 11:50:23 failed to execute query SET SESSION wait_timeout=2147483, max_statement_time=0: Access denied for user 'backup_shard_0'@'ctrl-02' (using password: YES)\n", "stderr_lines": ["INFO:__main__:Loading config file at /var/lib/kolla/config_files/config.json", "INFO:__main__:Validating config file", "INFO:__main__:Kolla config strategy set to: COPY_ALWAYS", "INFO:__main__:Copying service configuration files", "INFO:__main__:Deleting /etc/mysql/my.cnf", "INFO:__main__:Copying /var/lib/kolla/config_files/my.cnf to /etc/mysql/my.cnf", "INFO:__main__:Setting permission for /etc/mysql/my.cnf", "INFO:__main__:Writing out command to execute", "INFO:__main__:Setting permission for /var/log/kolla/mariadb", "INFO:__main__:Setting permission for /backup", "[00] 2023-10-31 11:50:23 Connecting to MariaDB server host: 10.224.133.131, user: backup_shard_0, password: set, port: 3306, socket: not set", "[00] FATAL ERROR: 2023-10-31 11:50:23 failed to execute query SET SESSION wait_timeout=2147483, max_statement_time=0: Access denied for user 'backup_shard_0'@'ctrl-02' (using password: YES)"], "stdout": "Taking a full backup\n", "stdout_lines": ["Taking a full backup"]}
Password for user backup_shard_0 is not correct
ctrl-01:~# cat /etc/kolla/proxysql/users/mariadb.yaml
mysql_users:
- username: "root_shard_0"
password: "cGwdsSKM42857jQ8JOfhywbFq3LfkvT6LQBqLVcg"
default_hostgroup: 0
transaction_persistent: 1
active: 1
- username: "backup_shard_0"
password: "cGwdsSKM42857jQ8JOfhywbFq3LfkvT6LQBqLVcg"
default_hostgroup: 0
transaction_persistent: 1
active: 1
The password is taken from database_password, but should be taken from mariadb_backup_database_password
Was proposed to fix this misunderstanding https://review.opendev.org/c/openstack/kolla-ansible/+/900979