[debian-mysql] Bug#875890: Further information

John Winters john at sinodun.org.uk
Thu Dec 17 15:39:55 GMT 2020


 > Trying to reload apparmor policies did not help, it appears that
 > apparmor_parser ignores policies that are empty?

A further data point on this - I have been struggling with much the same 
problem upgrading from Stretch + MySql to Buster + MariaDB.  Despite 
having the supplied empty AppArmor profile file in place, MySql was 
unable to initialise its database files nor to run.  Querying AppArmor 
with "sudo aa-status" indicated that the restrictions were still in 
place, although not apparently defined anywhere.

It appears that AppArmor *caches* a binary version of each profile 
configuration file, and if its binary cache is newer than the text file 
then it assumes that it doesn't need to recompile, so you end up with an 
out-of-date configuration and MySql can't run.

Two suggestions:

1) As part of the installation process, touch the supplied 
/etc/apparmor.d/usr.sbin.mysqld file so that it gets re-compiled.

2) Explicitly invoke apparmor_parser as part of the installation of the 
file, forcing it to be compiled.

Cheers,
John Winters

-- 
Xronos Scheduler - https://xronos.uk/
All your school's schedule information in one place.
Timetable, activities, homework, public events - the lot
Live demo at https://schedulerdemo.xronos.uk/



More information about the pkg-mysql-maint mailing list