Apparmor, aa-genprof doesn't work

I would like to generate new apparmor profile with aa-genprof, but I always get this error:


sudo aa-genprof /opt/pCloud/pcloud

ERROR: Include file /etc/apparmor/profiles/extras/rsyslog.d not found

Do you know, what is wrong with it?

A guess: some Apparmor profile refers to the mentioned file, but it doesn’t exist.

What does “grep -R rsyslog.d /etc/apparmor/” say?

AFAICT /etc/apparmor/profiles is not used on openSUSE, at least I don’t have that directory here on Leap (and it’s not part of the Tumbleweed package either).

Btw, I found a similar thread here, but that’s quite old:
https://forums.suse.com/showthread.php?6322-Apparmor-genprof-throwing-error-(Can-t-find-rsyslog-d)
In that case it was apparently a bug in the profile for rsyslog which contained a wrong include.

At that time (2015), /etc/apparmor/profiles/extras/rsyslog.d apparently did exist as part of the rsyslog package (in SLE12 at least). But that’s no longer the case in current Leap or Tumbleweed AFAICS.

What does “grep -R rsyslog.d /etc/apparmor/” say?

Nothing. I will try to go through the the previously mentioned topic.

I don’t think that will help.

Maybe it’s something in /opt/pCloud/ then?
Try “grep -R rsyslog.d /opt/pCloud/”.

No, there’s nothing.

Sorry, my first grep was slightly wrong, it should search in /etc/apparmor.d/ as well.
So try either:

grep -R rsyslog.d /etc/apparmor*/

or

grep -R rsyslog.d /etc/apparmor.d/

And you should do that as root (or with sudo), otherwise you’d probably just get “no permission” errors.

It doesn’t find anything.

Sorry for the delay :).