![mysql.service:主进程已退出,代码=killed,状态=9/KILL](https://linux22.com/image/779647/mysql.service%EF%BC%9A%E4%B8%BB%E8%BF%9B%E7%A8%8B%E5%B7%B2%E9%80%80%E5%87%BA%EF%BC%8C%E4%BB%A3%E7%A0%81%3Dkilled%EF%BC%8C%E7%8A%B6%E6%80%81%3D9%2FKILL.png)
我在单核 1GB RAM 服务器上运行 MySql Server 和 dotnet core 服务。我意识到我们的服务抛出了 mysql 连接错误。经过一番调查,我发现 mysql 服务被系统终止了。
我将服务器 RAM 和 CPU 增加到 2 核 4 GB,仍然出现此错误。这种情况并不常见,但我仍然会遇到此错误。
可能存在什么问题?
此致!
journalctl -u mysql
输出:
Aug 17 06:18:59 servername systemd[1]: Starting MySQL Community Server...
Aug 17 06:19:01 servername systemd[1]: Started MySQL Community Server.
Aug 17 11:20:22 servername systemd[1]: mysql.service: Main process exited, code=killed, status=9/KILL
Aug 17 11:20:22 servername systemd[1]: mysql.service: Failed with result 'signal'.
Aug 17 11:20:22 servername systemd[1]: mysql.service: Scheduled restart job, restart counter is at 1.
Aug 17 11:20:22 servername systemd[1]: Stopped MySQL Community Server.
Aug 17 11:20:22 servername systemd[1]: Starting MySQL Community Server...
Aug 17 11:20:24 servername systemd[1]: Started MySQL Community Server.
Aug 17 12:45:04 servername systemd[1]: mysql.service: Main process exited, code=killed, status=9/KILL
Aug 17 12:45:04 servername systemd[1]: mysql.service: Failed with result 'signal'.
Aug 17 12:45:05 servername systemd[1]: mysql.service: Scheduled restart job, restart counter is at 2.
Aug 17 12:45:05 servername systemd[1]: Stopped MySQL Community Server.
Aug 17 12:45:05 servername systemd[1]: Starting MySQL Community Server...
Aug 17 12:45:07 servername systemd[1]: Started MySQL Community Server.
Aug 17 14:27:14 servername systemd[1]: mysql.service: Main process exited, code=killed, status=9/KILL
Aug 17 14:27:14 servername systemd[1]: mysql.service: Failed with result 'signal'.
Aug 17 14:27:14 servername systemd[1]: mysql.service: Scheduled restart job, restart counter is at 3.
Aug 17 14:27:14 servername systemd[1]: Stopped MySQL Community Server.
Aug 17 14:27:14 servername systemd[1]: Starting MySQL Community Server...
Aug 17 14:27:15 servername systemd[1]: Started MySQL Community Server.
Aug 18 06:54:12 servername systemd[1]: mysql.service: Main process exited, code=killed, status=9/KILL
Aug 18 06:54:12 servername systemd[1]: mysql.service: Failed with result 'signal'.
Aug 18 06:54:12 servername systemd[1]: mysql.service: Scheduled restart job, restart counter is at 4.
Aug 18 06:54:12 servername systemd[1]: Stopped MySQL Community Server.
Aug 18 06:54:12 servername systemd[1]: Starting MySQL Community Server...
Aug 18 06:54:14 servername systemd[1]: Started MySQL Community Server.
Aug 18 11:17:09 servername systemd[1]: mysql.service: Main process exited, code=killed, status=9/KILL
Aug 18 11:17:09 servername systemd[1]: mysql.service: Failed with result 'signal'.
Aug 18 11:17:09 servername systemd[1]: mysql.service: Scheduled restart job, restart counter is at 5.
Aug 18 11:17:09 servername systemd[1]: Stopped MySQL Community Server.
Aug 18 11:17:09 servername systemd[1]: Starting MySQL Community Server...
Aug 18 11:17:11 servername systemd[1]: Started MySQL Community Server.