Mysql & #39; root & #39; @ & #39; localhost & #39; & amp; 'root' @ '%' difference, mysqllocalhost

Source: Internet
Author: User

Mysql 'root' @ 'localhost' & 'root' @ '%' difference, mysqllocalhost

1.% allow connection from any ip address localhost allow connection from the Local Machine
2. dbfor studio mysql 6.2.280
%, The SQL file backed up using backup databases is not imported into another database (restore database)
In the case of localhost, backup databases can be used to import the SQL file in another database.
3. select * from mysql. proc to see their differences (procedure and function are the same)
db                name          type         specific_name lanage  sql_data_access                                                                                 definer 
  
  
work inventory_held_by_customer FUNCTION inventory_held_by_customer SQL READS_SQL_DATA NO DEFINER       root@localhost
work inventory_in_stock FUNCTION inventory_in_stock SQL READS_SQL_DATA NO DEFINER       root@localhost
game F_Dep_GetChildList FUNCTION F_Dep_GetChildList SQL CONTAINS_SQL NO DEFINER       user01@%
game F_Get_TaskDeviationEstimate FUNCTION F_Get_TaskDeviationEstimate SQL CONTAINS_SQL NO DEFINER       user01@%

Mysql problem: access denied for user 'root @ localhost' (using password: YES)

This error indicates that the root password is incorrect. If you do not know the root password, change the username and password that can be logged in.

---
The above is helpful to you.

After mysql is installed in linux, Access denied for user 'root' @ 'localhost' (using password: YES)

Let me give you a try. I used to solve this problem:
First, end the mysql process. Run the ps aux | grep mysql command to obtain the process ID and kill ID.
Next, run mysqld -- skip-grant-tables
Then, open another terminal and enter mysql-u root mysql
After entering, execute UPDATE user SET Password = PASSWORD ('My _ password') where USER = 'root ';
Run the command again. flush privileges;
Exit, restart mysql, and then run mysql-u root-p and enter your password. It should be OK.

Related Article

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.