mysqld_multi centos6.9 无法自启动求助

wittzhang 2018-03-22 02:16:13
下面是通过chkconfig配置多实例自动启动的过程,重启主机mysql实例无法自动启动,请各位大佬帮忙排错。谢谢。
[root@mysql1 ~]# uname -a
Linux mysql1 2.6.32-696.el6.x86_64 #1 SMP Tue Mar 21 19:29:05 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

[root@mysql1 ~]# cp /usr/local/mysql/support-files/mysqld_multi.server /etc/rc.d/init.d/mysqld_multi
[root@mysql1 ~]# chkconfig --add mysqld_multi
[root@mysql1 ~]# chkconfig --list |grep -i mysql
mysqld_multi 0:off 1:off 2:on 3:on 4:on 5:on 6:off

[root@mysql1 ~]# service mysqld_multi start
WARNING: my_print_defaults command not found.
Please make sure you have this command available and
in your path. The command is available from the latest
MySQL distribution.
ABORT: Can't find command 'my_print_defaults'.
This command is available from the latest MySQL
distribution. Please make sure you have the command
in your PATH.

[root@mysql1 ~]# which my_print_defaults
/usr/local/mysql/bin/my_print_defaults


下面是通过命令启动多实例的过程:
[root@mysql1 ~]# /etc/init.d/mysqld_multi report
Reporting MySQL servers
MySQL server from group: mysqld1 is not running
MySQL server from group: mysqld2 is not running
[root@mysql1 ~]# /etc/init.d/mysqld_multi start
[root@mysql1 ~]# /etc/init.d/mysqld_multi report
Reporting MySQL servers
MySQL server from group: mysqld1 is running
MySQL server from group: mysqld2 is running
...全文
540 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
wittzhang 2018-03-22
  • 打赏
  • 举报
回复
另外,把mysqld_multi放到/etc/rc.d/rc.local 下,重启主机,mysql也无法自动启动。 [root@mysql1 ~]# cat /etc/rc.d/rc.local #!/bin/sh # # This script will be executed *after* all the other init scripts. # You can put your own initialization stuff in here if you don't # want to do the full Sys V style init stuff. touch /var/lock/subsys/local /etc/init.d/mysqld_multi start

56,678

社区成员

发帖
与我相关
我的任务
社区描述
MySQL相关内容讨论专区
社区管理员
  • MySQL
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧