MySQL specific installation method see http://www.cnblogs.com/yoyotl/p/5752437.html
However, more instructions are needed for the self-starter section.
First, the problem phenomenon:
After the system restarts, it is found that the MYSQLD service starts normally, but application a that relies on MySQL database fails to start.
The view log shows that the link database failed when program a started.
Second, reason analysis:
The MYSQLD service is started normally.
The manual restart program A,a also works correctly at this time.
Conclusion: When program a starts, mysqld may not start.
Third, the starting sequence
The first thing to think about is to adjust the boot order of the MYSQLD service so that it is higher than my program A.
However, there is no startup script for Mysqld found under the/ETC/INIT.D path.
Iv. the solution of the idea
Follow the link to indicate that the installed mysqld is automatically started by default.
You can cancel the Mysqld self-boot and then write a startup script to make sure it starts before program a starts.
V. Solutions
1. Check the system's current default startup Project method, no longer a setup.
Systemctl List-unit-files
Execute this command to view the service startup and service status of the current system.
The results are shown below:
1 ... 2 Microcode.service 3 Mysql.service 4 Mysqld.service 5 networkmanager-dispatcher.service 6 ...
2. Cancel the mysqld self-boot
Systemctl Disable Mysqld
After executing the command, review the service status of the current system:
1 ... 2 Microcode.service 3 mysqld.service Disabled4 networkmanager-dispatcher.service 5 ...
3. Custom/etc/rc.local
First Execute systemctl start mysqld
Re-execute Starta
Problem solving.
CentOS 7 Program self-booting problem