Mysql cannot reboot the Error warning:world-writable config file '/etc/my.cnf ' is ignored resolution _MYSQL

Source: Internet
Author: User

Problem analysis

In the Shutdown database command found that MySQL can not be closed, the hint Warning: World-writable config file '/etc/my.cnf' is ignored , probably means that the permissions of the global writable, any user could write. MySQL is concerned about this file being maliciously modified by other users, so ignore the configuration file. So MySQL can't shut down.

Let's look at the whole process.

Restart MySQL

[Root@ttlsa ~]# service mysqld stop
warning:world-writable config file '/etc/my.cnf ' is ignored
warning:world-w ritable config file '/etc/my.cnf ' is ignored the
MySQL Manager or server PID file could not being found![ FAILED]

You can see that MySQL can't stop.

View permissions for MY.CNF

[Root@ttlsa ~]# ls-l/etc/my.cnf
-rwxrwxrwx 1 root 4878

Permission 777, any user can be changed my.cnf , there are a lot of security risks.

Fix MySQL Problem

[Root@ttlsa ~]# chmod 644/etc/my.cnf

MY.CNF is set to read and write to the user and not to be writable by other users.

Close MySQL

[Root@ttlsa ~]# service mysqld stop
shutting down MySQL. [OK]

MySQL shutdown succeeded. The problem is simple.

Summarize

The above is the entire content of this article, I hope the content of this article for everyone's study or work can bring certain help, if you have questions you can message exchange.

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.