The server requested authentication method unknown to the client

I’m trying to install on fedora 28 running apache2 (httpd) with php7.2.
When I enter my details on the install page, I get the following error:

Error while trying to create admin user: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client.

I’ve been searching for an answer, and there seems to something with the hash length of the password string, but I am unable to verify this. Does anybody have an idea about how to solve this?

bad user/password

1 Like

Mysql version please.

Default authenticate of MySQL 8.0.4 changed.

If 8.0.4 then

1 Like

Mysql version is 8.0.4, as you suggested. I took a good look at your link and it helped me find a solution.
I had to change the default authentication method in /etc/my.cnf to mysql_native_password and restart the server. Then I created a new database and user with the new settings, and now it works.
Thank you very much for your help stratege1401.

1 Like

One note with this change also that had me stumped for a good while was that i also needed to update my nextcloud database user to use mysql_native_password also

ALTER USER 'nextcloud'@'localhost' IDENTIFIED WITH mysql_native_password BY '<password>';

Fixed this in a pull request

To elaborate relative to general mariadb/mysql issues of this sort, be sure that your database ‘from’ and ‘to’ addresses has access to the database for that particular user. i.e. for adminer as well as any other service you will need to verify that the ip is correct.

In the case of running a service from docker you’ll want to make sure that the login account has an entry with something like this:



Note: this is a wide open GRANT -adjust as needed.

Thank you from all the staff here at TheNet4You Hosting Services Company.

Our hosting server is at

but our NextCloud server is at

We are running it on a NethServer and we are stuck with users not able to register nor log into site. We have only one account that can log in and use NextCloud easily…

We need some help, from either NethServer or ya’ll …

We would appreciate a feedback to what we are missing in our configuration setup.

Thank you for your help