What if mysql8 assigns several accounts and permissions to the Times if it is wrong?
The main content of this article is to explain "mysql8 assigns several accounts and permissions Times wrong how to do", interested friends might as well take a look. The method introduced in this paper is simple, fast and practical. Next let the editor to take you to learn "mysql8 assigns a few accounts and permissions Times what to do wrong"!
Introduction to MySQL 8.0 is a very exciting new version of the world's most popular open source database. Some key enhancements include: SQL window functions, common table expressions, NOWAIT and SKIP LOCKED, descending indexing, grouping, regular expressions, character sets, cost models, and histograms.
1. With mysql8.0.13 installed, I tried to assign several accounts and permissions, but an error was reported:
two。 Check the information and know that the allocation authority of mysql8 cannot be created by a hermit with a password. It is necessary to create an account first and then set permissions.
Enter the command:
Grant all privileges on test.* to 'test'@'%'
Another error was reported:
You are not allowed to create a user with GRANT
Do not allow to use grant command, how can there be no permissions, strange.
3. Then I thought of host in the mysql data table user
So modify host:
Update user set host='%' where user='test'
Execute it twice more.
Grant all privileges on test.* to 'test'@'%'
Success:
But the connection Navicat reported an error
This is because mysql8's encryption is different from Navicat's.
4. Modify the encryption method:
Alter user test identified with mysql_native_password by 'xxx'
Try again, done!
At this point, I believe that everyone on the "mysql8 allocation of several accounts and permissions Times wrong how to do" have a deeper understanding, might as well to the actual operation of it! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!