Home > Database > phpMyAdmin > Installing the latest version of MySQL results in an error when logging into phpMyAdmin

Installing the latest version of MySQL results in an error when logging into phpMyAdmin

angryTom
Release: 2019-11-26 14:42:16
Original
4405 people have browsed it

The following column phpmyadmin tutorial will introduce to you the solution to the error message when logging in to phpMyAdmin due to installing the latest version of MySQL. I hope it will be helpful to friends in need!

Installing the latest version of MySQL results in an error when logging into phpMyAdmin

Installing the latest version of MySQL results in an error when logging in to phpMyAdmin

After installing the latest version of mysql, log in with phpMyadmin , when encountering an error

The first error:

mysqli::real_connect(): (HY000/2002): No such file or directory
Copy after login

Solution:

Put /libraries/config.default.php and /config.

$cfg['Servers'][$i]['host'] = 'localhost'
Copy after login

in the sample.inc.php file is changed to

$cfg['Servers'][$i]['host'] = '127.0.0.1';
Copy after login

The second error:

mysqli_real_connect(): The server requested authentication method unknown to the client [caching_sha2_password]
mysqli_real_connect(): (HY000/2054): The server requested authentication method unknown to the client
Copy after login

Solution:

Terminal login mysql

mysql -u root -p
Copy after login

Modify authorized user

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password'
Copy after login

password is the mysql login password

Recommended tutorial:PHPMyAdmin

The above is the detailed content of Installing the latest version of MySQL results in an error when logging into phpMyAdmin. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
MySQL stops process
From 1970-01-01 08:00:00
0
0
0
Error when installing mysql on linux
From 1970-01-01 08:00:00
0
0
0
phpstudy cannot start mysql?
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template