Is you dmesg filling up with apparmor "DENIED" messages?

Mine was full of such from the profiles 'ubuntu_pro_esm_cache' and 'ubuntu_pro_apt_news' trying to open libraries (via python3) in non-system locations.

The solution is to add the corresponding profile override to '/etc/apparmor.d/local/', like so:

$ cat ubuntu_pro_apt_news
/opt/local/lib64/* rm,
@{HOME}/local/lib/* rm,

These are then included by ../<profile_name> and the 'errors' go away.

After you need to 'sudo systemctl reload apparmor' and if you did it right, the "error" messages should go away.

BTW: The "rm" are the permissions: 'r' is for read, 'm' is for mmap.

I started by adding 'r', then checking the log and adding whatever else it complained about.

These #apparmor profiles are checked when running 'apt update' on #Ubuntu and #LinuxMint, so the kernel log/dmesg would fill up just from the update manager running it periodically.