MySQL error 1042-can ' t get hostname to your address

Source: Internet
Author: User
Tags mysql client

Workaround:

The code is as follows Copy Code

Vim/etc/my.cnf

Add or modify the following two lines under the [MYSQLD] node

The code is as follows Copy Code

Skip-name-resolve

#忽略主机名的方式访问

The code is as follows Copy Code

Lower_case_table_names=1

#忽略数据库表名大小写

Restarting the MySQL service is OK.


Attention

The connection is rejected, stating that your password is wrong, you try the MySQL client login on the server and see if the root user is allowed to log on remotely.


//////////////////////////////////////////////////////////

I want to tell you that the Linux password is correct does not mean that the MySQL password is correct


Although all are the same as root, however, two root is not the same, one is the root of the operating system is the root of MySQL

Do not think that your MySQL installed when the installation of a MySQL account, thought he used the system certification, it is very silly.

The first question, the answer is complete.


Linux does not install a firewall, from the error you have given, has been very clear that this point, your software has been connected to the MySQL only connection, found that the password is wrong .... So, prompts you to give the error ...


Second question, finish.


I feel that automatic settings and manual settings do not have any real relationship, as long as IP in the same network segment, mutual access

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.