# mysql[HY000][2054] the server requested authentication method unkonwn to client (caching_sha2_password)



## rtsiresy (Feb 27, 2019)

Hey all,
So I ve got FEMP (nginx , mysql80 and php72)pack installed on freeBSD 11.2 and everything configured correectly;
... I copied my webapp in and imported the .sql file ... no problem ...
but then when I took my windows laptop to test it ... it prints the above message ... 
 Please any help would be welcome ...


----------



## SirDice (Feb 27, 2019)

Upgrading to MySQL 8.0 : Default Authentication Plugin Considerations - MySQL Server Blog
					

If you are upgrading your server to MySQL 8.0 and observe that your application is experiencing error related caching_sha2_password plugin, it is likely because your clients/connectors does not (yet) support caching_sha2_password plugin. To resolve this issue, you may consider using...



					mysqlserverteam.com


----------



## rtsiresy (Feb 27, 2019)

oh ... thanx ... was digging around for hours about that probem ... okay i' ll try this tomorrow as the server is at my workplace ... i' ll post for the result ... 
thank you again ...


----------



## Emrion (Feb 27, 2019)

Fall in this problem recently. You have to configure MySQL as *SirDice *show you, but you have also to change the authentification method of the user(s) you created.

You need to use mysql command line utility and commit a sql query. Something like:
`ALTER USER user  IDENTIFIED WITH mysql_native_password   BY 'password';`
Adapt _user_ and _password_.


----------



## rtsiresy (Feb 27, 2019)

Copy that ...
Danke


----------



## rtsiresy (Mar 6, 2019)

Sorry guys, I took a while. It was because internet connection at work was cut for a week but now I'm back.
And to continue the discussion, I did all the thing you guys asked me to do; and yes it fixed the error.
But then a new error related to sql_mode stuff has taken the place.
I guess I'm just going to switch to mysql57.


----------



## sean137 (Dec 27, 2020)

I seem to still have this problem today, with:

FreeBSD 12.2-RELEASE-p1
mysql 8.0.22
PHP 7.4.13
The workaround of using mysql_native_password of course still works.

But everything I've read suggests that after the last two years, the PHP mysqli connector now supports caching_sha2_password. Yet in my phpinfo() output, in the list of supported authentication methods in the "Loaded plugins" row of the "mysqlnd" section, I don't see caching_sha2_password listed.  Do others see it listed?


----------

