zoukankan      html  css  js  c++  java
  • MySQL之——提示"mysql deamon failed to start"错误的解决方法

    网站突然连接不上数据库,于是直接重启了一下服务器。进到cli模式下,执行 service myqsld start 发现还是提示"mysql deamon failed to start"错误信息

    # /etc/init.d/mysqld start
    MySQL Daemon failed to start.
    Starting mysqld: [FAILED]
    查看mysqld的log文件

    #less /var/log/mysqld.log
    其中一行是:
    /usr/libexec/mysqld: Can't change dir to ‘XXX' (Errcode: 13)
    首先是查看数据库日志
    [Warning] Can't create test file xxx.lower-test
    [Warning] Can't create test file xxx.lower-test
    /usr/libexec/mysqld: Can't change dir to '/xxx' (Errcode: 13)
    [ERROR] Aborting
    首先检查数据目录和日志目录的权限和所属用户,权限和所属用户都没问题,那应该是SELINUX的权限限制了
    # getenforce
    Enforcing
    就表明SELinux已经启用.只需要关闭即可。
    关闭方法:
    #setenforce 0 (0|1 开|关)
    或者
    setsebool ftpd_disable_trans 1

    ---------------------
    作者:冰 河
    来源:CSDN
    原文:https://blog.csdn.net/l1028386804/article/details/51645223/
    版权声明:本文为博主原创文章,转载请附上博文链接!

  • 相关阅读:
    python循环删除list中的元素
    Mysql主从同步原理简介
    python 3新式类的多继承
    面向对象之多态、多态性
    python的collections模块和functools模块
    Python(os和sys)使用
    javascript中的数据类型
    语法、关键保留字及变量
    使用JavaScript
    javascript的概述
  • 原文地址:https://www.cnblogs.com/zhoading/p/10297535.html
Copyright © 2011-2022 走看看