测试mysqld启动mysql server的时候,报如下错误:

2015-12-17 00:46:02 10785 [ERROR] Fatal error: Please read "Security" section of the manual to find out how to run mysqld as root!

2015-12-17 00:46:02 10785 [ERROR] Aborting

2015-12-17 00:46:02 10785 [Note] Binlog end
2015-12-17 00:46:02 10785 [Note] ./mysqld: Shutdown complete

原因:

这是因为在测试的时候,使用root来启动的。而从安全角度来讲,不建议用root用户启动。

解决方案:

1.在使用root用户启动的时候,带上--user=root,强制启动(不建议这么做,仅供测试)

# ./mysqld --user=root &
# ps -ef|grep mysql | grep -v grep
root 11055 11019 0 01:02 pts/0 00:00:00 ./mysqld --user=root

2.启动的时候,指定mysql用户

# ./mysqld --user=mysql &
# ps -ef|grep mysql |grep -v grep
mysql 11165 11100 2 01:06 pts/1 00:00:00 ./mysqld --user=mysql

3.在my.cnf指定用户

[mysqld]
user=mysql

[ERROR] Fatal error: Please read "Security" section of the manual to find out how to run mysqld as root!的更多相关文章

  1. Please read “Security” section of the manual to find out how to run mysqld as root!错误解决(转)

    2016-03-12T15:40:45.717762Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please ...

  2. mysql多实例配置下,用脚本启动mysql时,出现Please read "Security" section of the manual to find out how to run mysqld as root!

    [root@localhost 3308]# mysqld stop170414 0:35:28 [Note] --secure-file-priv is set to NULL. Operation ...

  3. Please read "Security" section of the manual to find out how to run mysqld as root!

    [root@test ~]# /usr/local/mysql/bin/mysqld2018-08-05T08:29:05.143142Z 0 [Warning] [MY-011070] [Serve ...

  4. mysql [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist (转载)

    mysql报错Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist 2013-11-2 ...

  5. [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist

    mysql 启动总是报错: 错误日志中显示: [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' ...

  6. [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.user' doesn't exist 160913 02:11:21 mysqld_safe mysqld from pid file /tmp/mysql.pid ended

    -- :: [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0 -- :: [Warning] InnoDB: New ...

  7. ERROR Fatal error during KafkaServer startup. Prepare to shutdown (kafka.server.KafkaServer)

    1.之前搭建的kafka,过了好久,去启动kafka,发现报如下下面的错误,有错误就要解决了. 然后参考:https://blog.csdn.net/hello_world_qwp/article/d ...

  8. [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.user' doesn't exist

    这个问题是由于data的目录下没有安装数据库表 解决方法: vi /etc/my.cnf 修改为正确的datadir=“xxxxx”即可 然后service mysqld start service ...

  9. Swift Error fatal error: unexpectedly found nil while unwrapping an Optional value

    致命的错误: 对一个为空的optional值进行解包. 强制解包(forced unwrapping): 在optional后面加叹号. 比如  "value!" 错误代码: le ...

随机推荐

  1. 【PAT】B1077 互评成绩计算(20 分)

    录入成绩,直接将所有同学给的分数相加,排序,减去最大和最小 省去了遍历一次 注意四舍五入 #include<cstdio> #include<string.h> #includ ...

  2. 6.2Python文件的操作(二)

    目录 目录 前言 (一)文件的定位 (二)文件的读操作 ==1.read()方法== ==2.readline()方法== ==3.readlines()方法== ==4.文件的遍历读法== (三)文 ...

  3. Django 项目连接数据库Mysql要安装mysqlclient驱动出错 : Failed building wheel for mysqlclient:

    1,如果直接用 CMD命令:pip install mysqlclient ,会安装出错. 2,解决问题,参考了这个博友的帖子:https://blog.csdn.net/qq_29784441/ar ...

  4. Python3编写网络爬虫09-数据存储方式二-JSON文件存储

    2.JSON文件存储 全称为JavaScript Object Notation 通过对象和数组的组合来表示数据,构造简洁且结构化程度非常高.是一种轻量级的数据交换格式 2.1 对象和数组 在Java ...

  5. python框架面试题联系

    1.对 MVC,MVT 解读的理解? M:Model,模型,和数据库进行交互 V:View,视图,负责产生 Html 页面 C:Controller,控制器,接收请求,进行处理,与 M 和 V 进行交 ...

  6. el-table复选框分页记忆

    el-table 结合 el-pagination 实现分页后默认是没有复选框记忆功能的,对于这样的需求,无奈又只能硬着头皮上,试了网上的一些方法,没奏效,便自己上了. 简单的用法如下: <te ...

  7. 【LGP5176】公约数

    题目 老年选手啥都不想推只能搞个杜教筛了 这个式子长得好吓人啊,所以我们唯一分解之后来考虑这道题 设\(i,j,k\)分别是\(p^a,p^b,p^c\),至于到底谁是谁并不重要,我们不妨假设\(a\ ...

  8. ORB-SLAM2(3) ROS下实时跑ORB_SLAM2

    Step1 : 运行内核 roscore Step2 : 启动相机 cd catkin_ws/src/usb_cam/launch #进入usb_cam驱动的安装目录 roslaunch my_cam ...

  9. Python高级网络编程系列之第二篇

    在上一篇中,我们深入探讨了TCP/IP协议的11种状态,理解这些状态对我们编写服务器的时候有很大的帮助,但一般写服务器都是使用C/Java语言,因为这些语言对高并发的支持特别好.我们写的这些简单的服务 ...

  10. rman restore spfile from backup

    spfile一般在$ORACLE_HOME/dbs(linux)目录,如果你丢失了spfile并不会引起实例立刻停掉,你的实例可以继续操作,尽管当你restore spfile的时候需要关闭重启实例, ...