Mysql将不会在Ubuntu服务器16.04上启动或重启

时间:2019-05-30 20:38:04

标签: mysql ubuntu virtual-machine

嗨,我尝试重新启动MySQL时,已经用ubuntu服务器16.04创建了虚拟机,但出现以下错误 mysql.service的作业失败,因为控制进程退出并显示错误代码。

systemctl状态mysql.service错误报告

 Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset: enabled)
 Active: activating (start-post) (Result: exit-code) since Thu 2019-05-30 22:31:32 SAST; 28s ago
 Process: 11476 ExecStart=/usr/sbin/mysqld (code=exited, status=1/FAILURE)
 Process: 11467 ExecStartPre=/usr/share/mysql/mysql-systemd-start pre (code=exited, status=0/SUCCESS)
 Main PID: 11476 (code=exited, status=1/FAILURE);         : 11477 (mysql-systemd-s)
 Tasks: 2
 Memory: 320.0K
 CPU: 850ms
 CGroup: /system.slice/mysql.service
       └─control
         ├─11477 /bin/bash /usr/share/mysql/mysql-systemd-start post
         └─11564 sleep 1

 May 30 22:31:32 richardchristiaan systemd[1]: Starting MySQL Community Server...
 May 30 22:31:35 richardchristiaan systemd[1]: mysql.service: Main process exited, code=exited, status=1/FAILURE

journalctl -xe错误代码

            -- Unit mysql.service has finished shutting down.
        May 30 22:33:35 richardchristiaan systemd[1]: Starting MySQL Community Server...
        -- Subject: Unit mysql.service has begun start-up
        -- Defined-By: systemd
        -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
        --
        -- Unit mysql.service has begun starting up.
        May 30 22:33:35 richardchristiaan audit[11888]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11888/status" pid=11888 comm="mysqld" requ
        May 30 22:33:35 richardchristiaan audit[11888]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/sys/devices/system/node/" pid=11888 comm="mysql
        May 30 22:33:35 richardchristiaan audit[11888]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11888/status" pid=11888 comm="mysqld" requ
        May 30 22:33:35 richardchristiaan kernel: audit: type=1400 audit(1559248415.878:322): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11888/st
        May 30 22:33:35 richardchristiaan kernel: audit: type=1400 audit(1559248415.878:323): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/sys/devices/s
        May 30 22:33:35 richardchristiaan kernel: audit: type=1400 audit(1559248415.878:324): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11888/st
        May 30 22:33:38 richardchristiaan systemd[1]: mysql.service: Main process exited, code=exited, status=1/FAILURE
        May 30 22:34:06 richardchristiaan systemd[1]: Failed to start MySQL Community Server.
        -- Subject: Unit mysql.service has failed
        -- Defined-By: systemd
        -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
        --
        -- Unit mysql.service has failed.
        --
        -- The result is failed.
        May 30 22:34:06 richardchristiaan systemd[1]: mysql.service: Unit entered failed state.
        May 30 22:34:06 richardchristiaan systemd[1]: mysql.service: Failed with result 'exit-code'.
        May 30 22:34:06 richardchristiaan systemd[1]: mysql.service: Service hold-off time over, scheduling restart.
        May 30 22:34:06 richardchristiaan systemd[1]: Stopped MySQL Community Server.
        -- Subject: Unit mysql.service has finished shutting down
        -- Defined-By: systemd
        -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
        --
        -- Unit mysql.service has finished shutting down.
        May 30 22:34:06 richardchristiaan systemd[1]: Starting MySQL Community Server...
        -- Subject: Unit mysql.service has begun start-up
        -- Defined-By: systemd
        -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
        --
        -- Unit mysql.service has begun starting up.
        May 30 22:34:06 richardchristiaan audit[11991]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11991/status" pid=11991 comm="mysqld" requ
        May 30 22:34:06 richardchristiaan audit[11991]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/sys/devices/system/node/" pid=11991 comm="mysql
        May 30 22:34:06 richardchristiaan audit[11991]: AVC apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11991/status" pid=11991 comm="mysqld" requ
        May 30 22:34:06 richardchristiaan kernel: audit: type=1400 audit(1559248446.611:325): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11991/st
        May 30 22:34:06 richardchristiaan kernel: audit: type=1400 audit(1559248446.611:326): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/sys/devices/s
        May 30 22:34:06 richardchristiaan kernel: audit: type=1400 audit(1559248446.611:327): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/11991/st
        May 30 22:34:08 richardchristiaan systemd[1]: mysql.service: Main process exited, code=exited, status=1/FAILURE

这是我第一次与ubuntu合作,因此非常感谢您

0 个答案:

没有答案