Plugin caching_sha2_password could not be loaded
Closed this issue · 1 comments
muety commented
I got the following error when trying to run the parser.
DBI connect('database=dmarc;host=172.17.0.4;port=3306','dmarc',...) failed: Plugin caching_sha2_password could not be loaded: /usr/lib/x86_64-linux-gnu/mariadb19/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory at ./dmarcts-report-parser.pl line 266.
dmarcts-report-parser.pl: Cannot connect to database
In the meanwhile, I figured out that the following SQL query helped work around the issue:
ALTER USER 'user'@'localhost' IDENTIFIED WITH mysql_native_password BY 'sshhh';
Maeglin73 commented
If you're using the MariaDB client with a MySQL server, this is to be expected. The server uses caching_sha2_password by default for authentication when creating new users, and the MariaDB client doesn't know how to do that. Changing to the mysql_native_password auth plugin is the fix.