• linux下mysql提示"mysql deamon failed to start"错误的解决方法


    操作系统为centos,网站突然连接不上数据库,于是朋友直接重启了一下服务器。进到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
    141201 11:35:20 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
    141201 11:35:43 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
    141201 11:35:43 [Warning] '--default-character-set' is deprecated and will be removed in a future release. Please use '--character-set-server' instead.
    141201 11:35:43  InnoDB: Initializing buffer pool, size = 8.0M
    141201 11:35:43  InnoDB: Completed initialization of buffer pool
    141201 11:35:43  InnoDB: Started; log sequence number 0 44233
    141201 11:35:43 [ERROR] Can't start server: Bind on TCP/IP port: Permission denied
    141201 11:35:43 [ERROR] Do you already have another mysqld server running on port: 12345 ?
    141201 11:35:43 [ERROR] Aborting

    说明应该是SELINUX的权限限制了,需要关掉selinux

    查看当前配置信息.

    # getenforce

    Enforcing

    就表明SELinux已经启用.只需要关闭即可。

    关闭方法:

    /usr/sbin/setenforce 0(0|1 开|关)

    或者

    setsebool ftpd_disable_trans 1

  • 相关阅读:
    nyoj 95 众数问题(set)
    nyoj 93 汉诺塔(三)(stack)
    hdu 1010 Tempter of the Bone
    nyoj 55 懒省事的小明(priority_queue优先队列)
    nyoj 31 5个数求最值
    poj 1256 Anagram
    next_permutation函数
    nyoj 19 擅长排列的小明(深搜,next_permutation)
    nyoj 8 一种排序(用vector,sort,不用set)
    nyoj 5 Binary String Matching(string)
  • 原文地址:https://www.cnblogs.com/tianlangshu/p/5665300.html
Copyright © 2020-2023  润新知