Skip to content

apparmor_parser: Unable to load profile "php-fpm". Profile already exists #61690

Description

@TeusLollo

Is this a new report?

Yes

System Info

Void 6.18.40_1 x86_64 GenuineIntel uptodate rrrr

Package(s) Affected

apparmor-4.1.7_1

Does a report exist for this bug with the project's home (upstream) and/or another distro?

No response

Expected behaviour

Seems that a part of necessary post-install hook was removed, preventing proper installation in case you have a pre-installed php-fpm profile under /etc/apparmor.d/. More on that below

Actual behaviour

After updating to 4090fef , runit initialization output started throwing the following:

=> Loading AppArmor profiles...
apparmor_parser: Unable to load profile "php-fpm". Profile already exists
=>Initialization complete, running stage 2...

Indeed, it can be easily guessed why, since upon merging 4090fef, into ‎srcpkgs/apparmor/template, the following appears to have been removed under post_install() { :

- # we installed a custom conflicting profile
- rm ${DESTDIR}/etc/apparmor.d/{,local/}php-fpm

This will not throw a conventional apparmor_status error, however, since the pre-installed php-fpm profile was already present and workable. You need to monitor runit initialization to see this error, and it appears related to a post-install (Missing?) routine.

This probably will not appear upon a new apparmor-4.1.7_1 install. Package has never been set on hold or otherwise delayed by the package manager.

Steps to reproduce

1 Ensure you have a pre-installed php-fpm profile under /etc/apparmor.d/

2 Update to 4090fef

3 Monitor runit initialization output before stage 2 at the => Loading AppArmor profiles... section

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingneeds-testingTesting a PR or reproducing an issue needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions