Home Backend Development PHP7 Detailed explanation of PHP7.4 and MySQL8 certification issues

Detailed explanation of PHP7.4 and MySQL8 certification issues

Jan 29, 2020 pm 02:20 PM
mysql8

The default password encryption method of

Detailed explanation of PHP7.4 and MySQL8 certification issues

##mysql8 is caching_sha2_password, PHP7.4 connects to mysql The encryption method is also caching_sha2_password, you should pay attention to this place.

In order to be compatible with older versions of clients, not only PHP, but also problems during master-slave replication, the authentication method of mysql8 was changed back to

mysql_native_password.

If you use PHP7.4, an authentication error will be reported here, because 7.4 is the

caching_sha2_password encryption method, so I can switch to PHP7.2 here;

Without changing the configuration, you can use the following method to change the encryption method of mysql8 and change the password for the root user:

USE mysql;
ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY '123456';
FLUSH PRIVILEGES;
Copy after login

Detailed explanation of PHP7.4 and MySQL8 certification issues

Newly install php7.2;

apt-get install php7.2-fpm php7.2-mysql and other extensions;

Change the listening port to something else, and nginx reverse proxy this port.

For more php7 related knowledge, please visit the

php7 tutorial column!

The above is the detailed content of Detailed explanation of PHP7.4 and MySQL8 certification issues. For more information, please follow other related articles on the PHP Chinese website!

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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)