error: Please read "Security" section of the manual to find out how to run mysqld as root! 报错

本文记录了在CentOS7.2上安装MySQL5.7.21的过程及遇到的问题,包括初始化过程中出现的警告与错误提示,并给出了如何解决这些问题的方法。

centos7.2 安装 mysqld 5.7.21

初始化是
[root@localhost ~]# mysqld --initialize--user=mmysql
2018-08-07T16:22:02.572082Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2018-08-07T16:22:02.573515Z 0 [Note] mysqld (mysqld 5.7.21) starting as process 5834 ...
2018-08-07T16:22:02.575125Z 0 [ERROR] Fatal error: Please read "Security" section of the manual to find out how to run mysqld as root!

2018-08-07T16:22:02.575159Z 0 [ERROR] Aborting

2018-08-07T16:22:02.575171Z 0 [Note] Binlog end
2018-08-07T16:22:02.575217Z 0 [Note] mysqld: Shutdown complete

 

删除rpm安装时生成的文件

datadir=/var/lib/mysql

解决方法

保证 --datadir目录为空。/var/lib/mysql 这个目录 

 

 

转载于:https://www.cnblogs.com/macupdate/p/9440508.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值