-
Problem report
-
Resolution: Unresolved
-
Trivial
-
None
-
4.0.19, 4.4.7
-
None
-
MySQL 8
When installing server/proxy and creating a user in MySQL 8.0 using existing documentation. Zabbix service returns this error in logfile:
13242:20200407:155638.865 [Z3001] connection to database 'zabbix' failed: [2059] Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory
This is due to MySQL 8 changing their default authentication modules to caching_sha2_password. Users need to be created using old auth method 'mysql_native_password' or MySQL needs to be configured to use the old one as its default
MySQL my.cnf
[mysqld]
default-authentication-plugin=mysql_native_password
Please update documentation when using MySQL 8 as DB:
create database zabbix character set utf8 collate utf8_bin; create user 'zabbix'@'localhost' identified with mysql_native_password by '<PASSWORD>'; grant all privileges on zabbix.* to 'zabbixuser'@'localhost';
and/or support new MySQL authentication method
More info on this topic had been summarized here:
https://medium.com/@crmcmullen/how-to-run-mysql-8-0-with-native-password-authentication-502de5bac661