I just ran into Robie's problem at my site. I have a 16.04 server setup in a VM running mysql 5.7.17 Community Edition.
About two weeks ago, we started having the mysqld throw apparmor errors and die every day at a random time. What appears to be happening is the daily apt update is trying to update mysql. The random time is a consequence of it being run by the systemd timer for cron.daily. For some reason, part of that update involves a configuration change to mysqld. /etc$ sudo apt-get upgrade --simulate | grep -i sql Conf mysql-server-5.7 (5.7.17-0ubuntu0.16.04.1 Ubuntu:16.04/xenial-updates, Ubuntu:16.04/xenial-security [amd64]) At that time, either during shutdown or reload, mysqld is trying to check the status of itself (or the previous instance?) and is being rejected by apparmor: Mar 22 11:57:45 SERVERNAME kernel: [16429106.693912] audit: type=1400 audit(1490198265.911:133): apparmor="DENIED" operation="open" profile="/usr/sbin/mysqld" name="/proc/7135/status" pid=7135 comm="mysqld" requested_mask="r" denied_mask="r" fsuid=111 ouid=111 -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1610765 Title: Apparmor refuses mysqld open on /etc/mysql/my.cnf.migrated causing it to fail to start To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1610765/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs