Php 5.6 with mysql 8.0 poblem with mysql_native_password

January 13, 2020 76 views
MySQL Apache

Hi guys,

I have a “Droplets” with apache2, php 5.6 and I have my project installed https://www.jonyram.dev/. On the other hand I have a database server with MySQL 8.0.

I was investigating and I need to make a modification in the database users, which I did next the results of my query “select Host, User, plugin from mysql.user”.

’%’,‘CBAUTISTA’,'mysqlnativepassword’
’%’,'CORE’,'mysqlnativepassword’

The project works correctly in https://administracion.cbautista.cl/, but it is another “Droplets”, I think the problem is in the configuration of php5.6 on both servers, because the database server that I try to connect is the same.

Does anybody have an idea?

1 Answer

Hey @UMPALUMPA

This Stack overflow question has a very detailed answer to your question

However a quick (not recommended way round your issue is to run the following SQL command on the server

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

Hope this helps.

Regards

Simon
DigitalOcean Backups - SnapShooter

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!