As you can read in my previous post related to MySQL 9 and
authentication, the old mysql_native_password
plugin
has been removed.
In that post, I showed an example using PHP 7.2, the default version in OL8.
If you are using PHP and you want to use MySQL 9, you must be
using a more recent version that fully supports the default
authentication plugin caching_cha2_password
.
Here is a summary table illustrating which PHP versions are compatible with MySQL 9:
This is the test using OL8 and PHP from the official repository and from Remi’s repo:
[root@mysql1 ~]# php test.php
PHP version: 7.2.24
PHP Warning: mysqli::__construct(): The server requested authentication method
unknown to the client …
[Read more]