canonical-ubuntu-qa team mailing list archive
-
canonical-ubuntu-qa team
-
Mailing list archive
-
Message #02718
[Bug 2000901] Re: aa-logprof complained about libvirt include file not found on K-s390x
** Tags added: 5.15 jammy
** Tags added: sru-20240108
--
You received this bug notification because you are a member of Canonical
Platform QA Team, which is subscribed to ubuntu-kernel-tests.
https://bugs.launchpad.net/bugs/2000901
Title:
aa-logprof complained about libvirt include file not found on K-s390x
Status in ubuntu-kernel-tests:
New
Bug description:
When you try to run aa-logprof on s390x instances (zVM / LPAR), it will complain about:
$ aa-logprof
ERROR: Include file /etc/apparmor.d/libvirt/libvirt-df90c3d2-e35c-4914-9b8a-a6958234d0e0.files not found
$ echo $?
1
This is causing test failures in ubuntu_qrt_apparmor tests, for those tests that will call aa-logprof, because of this non-zero return value:
* ApparmorTest.test_lp652674
* ApparmorTest.test_lp1243932_send
* ApparmorTest.test_lp1243932_receive
* ApparmorTest.test_lp1243932_bind
* ApparmorTestsuites.test_utils_testsuite
* ApparmorTestsuites.test_utils_testsuite3
One example output:
Running 'python3 ./test-apparmor.py -v ApparmorTest.test_lp652674'
Running test: './test-apparmor.py' distro: 'Ubuntu 22.10' kernel: '5.19.0-28.29 (Ubuntu 5.19.0-28.29-generic 5.19.17)' arch: 's390x' uid: 0/0 SUDO_USER: 'ubuntu')
test_lp652674 (__main__.ApparmorTest)
Test aa-logprof LP: #652674 ... FAIL
======================================================================
FAIL: test_lp652674 (__main__.ApparmorTest)
Test aa-logprof LP: #652674
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/ubuntu/autotest/client/tmp/ubuntu_qrt_apparmor/src/qa-regression-testing/scripts/./test-apparmor.py", line 895, in test_lp652674
self._test_logprof(log_contents, 0, 'SubDomain.pm')
File "/home/ubuntu/autotest/client/tmp/ubuntu_qrt_apparmor/src/qa-regression-testing/scripts/./test-apparmor.py", line 889, in _test_logprof
self.assertEqual(expected_rc, rc, result + report)
AssertionError: 0 != 1 : Got exit code 1, expected 0
ERROR: Include file /etc/apparmor.d/libvirt/libvirt-
df90c3d2-e35c-4914-9b8a-a6958234d0e0.files not found
----------------------------------------------------------------------
Ran 1 test in 0.777s
FAILED (failures=1)
Skipping private tests
This is not a regression, it's just the ubuntu_qrt_apparmor test
granularity improvement (bug 1982439) make it easier to spot this
failure.
Take a closer look into /usr/lib/python3/dist-packages/apparmor/aa.py,
this failure happens in loadincludes(), when trying to load the file
in /etc/apparmor.d/libvirt/
$ ls
libvirt-6e3ec251-b475-43eb-bbc1-a7844b0d8e86 TEMPLATE.lxc TEMPLATE.qemu
$ cat libvirt-6e3ec251-b475-43eb-bbc1-a7844b0d8e86
#
# This profile is for the domain whose UUID matches this file.
#
#include <tunables/global>
profile libvirt-6e3ec251-b475-43eb-bbc1-a7844b0d8e86 flags=(attach_disconnected) {
#include <abstractions/libvirt-qemu>
#include <libvirt/libvirt-6e3ec251-b475-43eb-bbc1-a7844b0d8e86.files>
}
$
The include file here, libvirt-6e3ec251-b475-43eb-
bbc1-a7844b0d8e86.files, will cause this file not found error.
It seems this /etc/apparmor.d/libvirt/libvirt-* file was created with
uvt-kvm. One new file will be created when we run the
ubuntu_kvm_smoke_test once.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/2000901/+subscriptions