I'm attaching a tarball of an example apparmor directory, sanitized a bit for environment-specific things. since the last update, I've had time to test on additional server configurations, and it does seem that the cache size required to overflow the kernel is a function of total memory - the cache file generated by this usr.sbin.apache2 profile will crash a 4 gigabyte box after ~4000 loops of `apparmor_parser -rB`, but not a larger machine. Unfortunately, that also means I don't yet have reliable steps to reproduce the slowdown condition, as the out of memory condition happened first on the smaller test environment. I am continuing to test on an 8-core 30-gigabyte machine with additional hats. Here's a diff of meminfo after several hundred passes vs several thousand, you can see the kernel eating memory for slabs, but it seems like we outpace slab reclamation with new allocation: MemTotal: 4045864 kB MemTotal: 4045864 kB 3683 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:06.51 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin MemFree: 2104988 kB | MemFree: 407040 kB 3694 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.09 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin MemAvailable: 2963900 kB | MemAvailable: 1270908 kB 3792 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.44 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Buffers: 118524 kB | Buffers: 118848 kB 3795 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Cached: 915136 kB | Cached: 924612 kB 3796 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin SwapCached: 0 kB SwapCached: 0 kB 3797 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Active: 815716 kB | Active: 816332 kB 3798 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Inactive: 593944 kB | Inactive: 603488 kB 3799 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.01 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Active(anon): 379872 kB | Active(anon): 380040 kB 3800 mysql 20 0 1281M 171M 20008 S 0.0 4.3 0:00.04 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin Inactive(anon): 44580 kB | Inactive(anon): 49832 kB F1Help F2Setup F3SearchF4FilterF5Tree F6SortByF7Nice -F8Nice +F9Kill F10Quit Active(file): 435844 kB | Active(file): 436292 kB 1 bash Inactive(file): 549364 kB | Inactive(file): 553656 kB Active / Total Objects (% used) : 850270 / 888877 (95.7%) Unevictable: 3656 kB Unevictable: 3656 kB Active / Total Slabs (% used) : 31518 / 31518 (100.0%) Mlocked: 3656 kB Mlocked: 3656 kB Active / Total Caches (% used) : 79 / 121 (65.3%) SwapTotal: 2097148 kB SwapTotal: 2097148 kB Active / Total Size (% used) : 349403.16K / 373125.54K (93.6%) SwapFree: 2097148 kB SwapFree: 2097148 kB Minimum / Average / Maximum Object : 0.01K / 0.42K / 8.00K Dirty: 412 kB | Dirty: 224 kB Writeback: 0 kB Writeback: 0 kB OBJS ACTIVE USE OBJ SIZE SLABS OBJ/SLAB CACHE SIZE NAME AnonPages: 357152 kB | AnonPages: 357448 kB 137970 127417 92% 0.19K 6570 21 26280K dentry Mapped: 226764 kB | Mapped: 227348 kB 136071 136071 100% 0.10K 3489 39 13956K buffer_head Shmem: 46040 kB | Shmem: 51100 kB 76534 76534 100% 0.12K 2251 34 9004K kernfs_node_cache Slab: 234096 kB | Slab: 376100 kB 67770 50089 73% 1.05K 2259 30 72288K ext4_inode_cache SReclaimable: 146524 kB | SReclaimable: 146960 kB 53760 53380 99% 0.06K 840 64 3360K anon_vma_chain SUnreclaim: 87572 kB | SUnreclaim: 229140 kB 50898 50655 99% 0.04K 499 102 1996K ext4_extent_status KernelStack: 11056 kB KernelStack: 11056 kB 39232 39006 99% 1.00K 2452 16 39232K kmalloc-1024 PageTables: 11740 kB | PageTables: 11672 kB 32960 28248 85% 0.06K 515 64 2060K kmalloc-64 NFS_Unstable: 0 kB NFS_Unstable: 0 kB 31872 31872 100% 0.03K 249 128 996K kmalloc-32 Bounce: 0 kB Bounce: 0 kB 31314 31314 100% 0.08K 614 51 2456K anon_vma WritebackTmp: 0 kB WritebackTmp: 0 kB 27500 27170 98% 0.20K 1375 20 5500K vm_area_struct CommitLimit: 4120080 kB CommitLimit: 4120080 kB 22015 22015 100% 0.05K 259 85 1036K ftrace_event_field Committed_AS: 2326844 kB | Committed_AS: 2336444 kB 19992 19472 97% 0.09K 476 42 1904K kmalloc-96 VmallocTotal: 34359738367 kB VmallocTotal: 34359738367 kB 19521 19302 98% 0.58K 723 27 11568K inode_cache VmallocUsed: 0 kB VmallocUsed: 0 kB 15400 14241 92% 0.57K 550 28 8800K radix_tree_node VmallocChunk: 0 kB VmallocChunk: 0 kB 14700 13977 95% 0.63K 588 25 9408K proc_inode_cache HardwareCorrupted: 0 kB HardwareCorrupted: 0 kB 14400 14348 99% 0.50K 900 16 7200K kmalloc-512 AnonHugePages: 221184 kB AnonHugePages: 221184 kB 12648 12595 99% 8.00K 3162 4 101184K kmalloc-8192 ShmemHugePages: 0 kB ShmemHugePages: 0 kB 12117 12057 99% 0.19K 577 21 2308K cred_jar ShmemPmdMapped: 0 kB ShmemPmdMapped: 0 kB 7344 6360 86% 0.25K 459 16 1836K kmalloc-256 CmaTotal: 0 kB CmaTotal: 0 kB 5376 5376 100% 0.02K 21 256 84K kmalloc-16 CmaFree: 0 kB CmaFree: 0 kB 5313 5313 100% 0.19K 253 21 1012K kmalloc-192 HugePages_Total: 0 HugePages_Total: 0 4608 4608 100% 0.01K 9 512 36K kmalloc-8 HugePages_Free: 0 HugePages_Free: 0 4456 4433 99% 4.00K 557 8 17824K kmalloc-4096 HugePages_Rsvd: 0 HugePages_Rsvd: 0 4448 4386 98% 0.12K 139 32 556K pid HugePages_Surp: 0 HugePages_Surp: 0 3300 3261 98% 0.62K 132 25 2112K sock_inode_cache Hugepagesize: 2048 kB Hugepagesize: 2048 kB 3216 3201 99% 2.00K 201 16 6432K kmalloc-2048 DirectMap4k: 67572 kB DirectMap4k: 67572 kB 3150 3004 95% 1.06K 105 30 3360K signal_cache DirectMap2M: 4126720 kB DirectMap2M: 4126720 kB 2912 2808 96% 0.12K 91 32 364K kmalloc-128 DirectMap1G: 2097152 kB DirectMap1G: 2097152 kB