From b165810a9cce501dad5ff8fcbede4a226add7e54 Mon Sep 17 00:00:00 2001 From: Patrick Vacek Date: Mon, 29 Apr 2019 10:47:00 +0200 Subject: selftest: Remove test_secondary_listening. The secondary discovery mechanism is being overhauled and that tool no longer exists. Signed-off-by: Patrick Vacek --- lib/oeqa/selftest/cases/updater_qemux86_64.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lib/oeqa/selftest/cases/updater_qemux86_64.py b/lib/oeqa/selftest/cases/updater_qemux86_64.py index bef6cdc..c928093 100644 --- a/lib/oeqa/selftest/cases/updater_qemux86_64.py +++ b/lib/oeqa/selftest/cases/updater_qemux86_64.py @@ -341,11 +341,6 @@ class SecondaryTests(OESelftestTestCase): self.assertEqual(retcode, 0, "Unable to run aktualizr-secondary --help") self.assertEqual(stderr, b'', 'Error: ' + stderr.decode()) - def test_secondary_listening(self): - print('Checking aktualizr-secondary service is listening') - stdout, stderr, retcode = self.qemu_command('aktualizr-check-discovery') - self.assertEqual(retcode, 0, "Unable to connect to secondary") - class PrimaryTests(OESelftestTestCase): def setUpLocal(self): -- cgit v1.2.3-54-g00ecf From 72b274c860851488b13026dae4660bed6146aaee Mon Sep 17 00:00:00 2001 From: Patrick Vacek Date: Tue, 23 Apr 2019 17:20:49 +0200 Subject: aktualizr: Bump to latest for recovery fixes. Signed-off-by: Patrick Vacek --- recipes-sota/aktualizr/aktualizr_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes-sota/aktualizr/aktualizr_git.bb b/recipes-sota/aktualizr/aktualizr_git.bb index 64382d8..8928736 100755 --- a/recipes-sota/aktualizr/aktualizr_git.bb +++ b/recipes-sota/aktualizr/aktualizr_git.bb @@ -33,7 +33,7 @@ SRC_URI = " \ SRC_URI[md5sum] = "c5e9968dfe78a7264ab9a8338c11725d" SRC_URI[sha256sum] = "3a19258d7a1825a308aca0da82f7a337985bec05e8951355c4c95f0fcf2444f4" -SRCREV = "9c5ef10b7b91cc7d51cd22fc60446e734cf84690" +SRCREV = "c50feb37034eceb1254429d3e3ed38e5b8a0dc60" BRANCH ?= "master" S = "${WORKDIR}/git" -- cgit v1.2.3-54-g00ecf From f68440e901522cc03c6151e8bca47117b18e5b6b Mon Sep 17 00:00:00 2001 From: Patrick Vacek Date: Mon, 29 Apr 2019 11:21:42 +0200 Subject: aktualizr: Remove aktualizr-check-discovery dependency. It no longer exists. Signed-off-by: Patrick Vacek --- recipes-sota/aktualizr/aktualizr_git.bb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/recipes-sota/aktualizr/aktualizr_git.bb b/recipes-sota/aktualizr/aktualizr_git.bb index 8928736..c0e275d 100755 --- a/recipes-sota/aktualizr/aktualizr_git.bb +++ b/recipes-sota/aktualizr/aktualizr_git.bb @@ -7,8 +7,7 @@ LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=9741c346eef56131163e13b9db1241b3" DEPENDS = "boost curl openssl libarchive libsodium sqlite3 asn1c-native" DEPENDS_append = "${@bb.utils.contains('PTEST_ENABLED', '1', ' coreutils-native ostree-native aktualizr-native ', '', d)}" -RDEPENDS_${PN}_class-target = "aktualizr-check-discovery aktualizr-configs lshw" -RDEPENDS_${PN}-secondary = "aktualizr-check-discovery" +RDEPENDS_${PN}_class-target = "aktualizr-configs lshw" RDEPENDS_${PN}-host-tools = "aktualizr aktualizr-repo aktualizr-cert-provider ${@bb.utils.contains('PACKAGECONFIG', 'sota-tools', 'garage-deploy garage-push', '', d)}" RDEPENDS_${PN}-ptest += "bash cmake curl python3-modules openssl-bin sqlite3 valgrind" -- cgit v1.2.3-54-g00ecf From 7fe4010668fa403fac2bed240365acb66ad723bd Mon Sep 17 00:00:00 2001 From: Patrick Vacek Date: Tue, 30 Apr 2019 16:04:35 +0200 Subject: selftest: retry aktualizr failure check due to resource constraints. For some reason it now often fails if you don't briefly pause first, so just retry it if it fails a few times. Signed-off-by: Patrick Vacek --- lib/oeqa/selftest/cases/updater_qemux86_64.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/lib/oeqa/selftest/cases/updater_qemux86_64.py b/lib/oeqa/selftest/cases/updater_qemux86_64.py index c928093..9f32bcf 100644 --- a/lib/oeqa/selftest/cases/updater_qemux86_64.py +++ b/lib/oeqa/selftest/cases/updater_qemux86_64.py @@ -408,11 +408,18 @@ class ResourceControlTests(OESelftestTestCase): def test_aktualizr_resource_control(self): print('Checking aktualizr was killed') - stdout, stderr, retcode = self.qemu_command('systemctl --no-pager show aktualizr') + ran_ok = False + for delay in [5, 5, 5, 5]: + sleep(delay) + stdout, stderr, retcode = self.qemu_command('systemctl --no-pager show aktualizr') + if retcode == 0 and b'ExecMainStatus=9' in stdout: + ran_ok = True + break + self.assertTrue(ran_ok, 'Aktualizr was not killed') + self.assertIn(b'CPUWeight=1000', stdout, 'CPUWeight was not set correctly') self.assertIn(b'MemoryHigh=52428800', stdout, 'MemoryHigh was not set correctly') self.assertIn(b'MemoryMax=1048576', stdout, 'MemoryMax was not set correctly') - self.assertIn(b'ExecMainStatus=9', stdout, 'Aktualizr was not killed') self.qemu_command('systemctl --runtime set-property aktualizr MemoryMax=') self.qemu_command('systemctl restart aktualizr') -- cgit v1.2.3-54-g00ecf