Mysql8 Change Password encryption method

Source: Internet
Author: User

Mysql8 with Navicat Visual connection error encryption method, want to connect Mysql8 there are two ways

1: Install the MYSQL8 client

2: Modify the password encryption method of MySQL8

I use the second type, because the server is MySQL8, and I am MySQL5, do not want to install a MySQL8, if the computer is also installed a MySQL8, feel a little trouble.

The following is a summary of the data through the revision method and the changes may occur during the process of problems. Time a bit long, the data address found forgotten, there is a change of record.

Landing

Mysql-uroot-p

Change the encryption method

Mysql> ALTER USER ' root ' @ '% ' identified by ' password ' password EXPIRE never; Query OK, 0 rows affected (0.02 sec)

Change Password

' Root '@'%'pwd12345'0 rows Affected (0.03 sec)

Refresh

mysql>0 rows affected (0.01 sec)

If error 1819 (HY000): Your password does not satisfy the current policy requirements

Use the following:

Set Global validate_password.policy=00 rows affected (0.00  sec) MySQL  Setglobal validate_password.length=80 rows affected (  0.00 sec)

If error 1396 (HY000): Operation ALTER USER failed for '% ':

mysql> use mysql;database changedmysqlSelect from user; +------------------+-----------+| user | Host |+------------------+-----------+| Mysql.infoschema | localhost | | mysql.session | localhost | | Mysql.sys | localhost | | Root | localhost |+------------------+-----------+<strong>5inset (<strong>  0.00</strong> sec)

Mysql8 Change Password encryption method

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.