重庆思庄Oracle、Redhat认证学习论坛

标题: mysqld_safe and mysqld_multi 在 5.7以后的版本不见了 [打印本页]

作者: 郑全    时间: 2018-7-9 17:30
标题: mysqld_safe and mysqld_multi 在 5.7以后的版本不见了
严格的说,是在rhel7系统上,如果使用rpm包安装,默认是没有这两个文件了。



作者: 郑全    时间: 2018-7-9 17:31
使用 二进制安装,还有。


作者: 郑全    时间: 2018-7-9 17:32
具体可以参见: (Doc ID 2418462.1)

The mysqld_safe and mysqld_multi Scripts Are Missing for MySQL 5.7 and Later on Red Hat Enterprise (RHEL) 7, Oracle Linux 7, CentOS 7, SUSE Linux Enterprise Server 12, Fedora 20 and Later (Doc ID 2418462.1)
To Bottom



In this Document

Symptoms

Changes

Cause

Solution

References


Applies to:
MySQL Server - Version 5.7 and later
Generic Linux
Symptoms
After installing or upgrading to MySQL Server 5.7 or later on Red Hat Enterprise (RHEL) 7, Oracle Linux 7, CentOS 7, SUSE Linux Enterprise Server (SLES) 12, Fedora 20 and later using RPMs, the mysqld_safe and mysqld_multi scripts are missing.
Changes
MySQL 5.7 or later has been installed or an existing MySQL instance have been upgraded.
Cause
The mysqld_safe and mysqld_multi scripts are not included on purpose as they are not required for MySQL Server 5.7 and later on RPM based installation for Linux distributions where systemd is availble.
Red Hat Enterprise (RHEL) 7, Oracle Linux 7, CentOS 7, SUSE Linux Enterprise Server (SLES) 12, Fedora 20 and later using RPMs use systemd to manage MySQL. systemd does not use mysqld_safe and systemd has native support for managing multiple instances so there is no need for mysqld_multi either.
Note: Native systemd support for managing multiple instances on the same host was not implemented until MySQL Server 5.7.13.

From the MySQL Server 5.7.6 release notes:
"mysqld now supports a --daemonize option that causes it to run as a traditional, forking daemon. This permits the server to work with operating systems that use systemd for process control. Advantages include automatic restarts after failure, handling of the user and group used to run the daemon, resource control, and temporary-file cleanup.

The new WITH_SYSTEMD CMake option, when enabled, causes installation of systemd support files. In addition, scripts such as mysqld_safe and the System V initialization script are not installed. On platforms where systemd is not available, enabling WITH_SYSTEMD results in an error from CMake. When WITH_SYSTEMD is enabled, the new SYSTEMD_SERVICE_NAME and SYSTEMD_PID_DIR options may also be used to specify the MySQL service name and directory in which the server creates the PID file, respectively.

Support files for systemd are installed when you install MySQL using an RPM distribution for these Linux platforms:

  Red Hat Enterprise Linux 7; Oracle Linux 7; CentOS 7

  SUSE Linux Enterprise Server 12

  Fedora 20, 21

..."


From the MySQL Server 5.7.13 release notes:

"On platforms for which systemd support is installed, systemd has the capability of managing multiple MySQL instances. For details, see Managing MySQL Server with systemd. Consequently, mysqld_multi and mysqld_multi.server are not installed because they are unnecessary. (Bug #81093, Bug #23134620)"
Solution
Use systemd to manage the instance(s). See:
Managing MySQL Server with systemd
An example for Using systemd to Configure and Manage Multiple MySQL Instances: systemctl (Doc ID 2228210.1)
Configuring Multiple MySQL Instances Using systemd
References
NOTE:2228210.1 - An example for Using systemd to Configure and Manage Multiple MySQL Instances: systemctl




欢迎光临 重庆思庄Oracle、Redhat认证学习论坛 (http://bbs.cqsztech.com/) Powered by Discuz! X3.2