Commit Graph

27 Commits

Author SHA1 Message Date
Luca Boccassi
b865dc9aae autopkgtest: disable networkd in rebooting tests
It seems that on Semaphore CI, running in Bullseye images, having
both Network-Manager and systemd-networkd enabled causes
'systemctl start network-online.target' to get stuck, and fail
the run. Disable networkd in those tests.

See: https://github.com/systemd/systemd/issues/22991
2022-05-15 14:10:07 +01:00
Dan Streetman
e4c364bc4c d/t/boot-smoke: update test to avoid false negatives 2021-05-07 12:23:58 +02:00
Michael Biebl
af25bbb8f6 d/t/boot-smoke: check for NetworkManager instead of D-Bus activated polkitd
polkit.service is started on-demand via D-Bus activation. This means it
is not a good indicator if a boot was successful. Instead check if
NetworkManager is running as it is started via multi-user.target.

Closes: #934992
2019-08-21 00:11:44 +02:00
Dan Streetman
3e5879804c d/t/boot-smoke: remove check for running jobs
The check for is-system-running handles verifying that systemd completes
all its jobs during startup, making this test redundant.  Also, since the
testbed can (and does) start more jobs after is-system-running, this test
can provide a false negative if any of those jobs continue running after
this check's timeout.
2019-08-12 11:24:55 -04:00
Dan Streetman
8e9bbcfe38 d/t/boot-smoke: call fail if pidof polkitd fails 2019-08-12 11:24:55 -04:00
Dan Streetman
d0ada35331 d/t/boot-smoke: wait for is-system-running
There is currently no delay to wait for is-system-running to reach running
or degraded, so it's very possible for there to be running jobs.  This adds
a delay until is-system-running is 'running' or 'degraded', and gathers
extra artifacts if the system is 'degraded'.

Additional details are in this Ubuntu bug:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1825997

Note that bug description states:
"This patch is not required for debian, because debian's boot-smoke does
not include the wait for systemctl is-system-running", however this patch
adds that wait, because without it, the check for running jobs can easily
fail, if the system isn't fully running yet.
2019-08-12 11:24:55 -04:00
Dan Streetman
f6d63ec4e1 d/t/boot-smoke: gather still running jobs in fail() 2019-08-12 11:24:53 -04:00
Dan Streetman
dc215aee10 d/t/boot-smoke: in fail() set +e so errors are ignored while gathering data 2019-08-12 11:24:50 -04:00
Dan Streetman
90298d3e23 d/t/boot-smoke: pass failure reason to fail() to print instead of separate echo 2019-08-12 10:42:28 -04:00
Martin Pitt
558fae47bf Revert "debian/tests/boot-smoke: Create "render" system group"
This reverts commit 2ab793c735.

Commit 8ca0c4921b creates the group in the package now.

Gbp-Dch: Ignore
2019-03-14 21:50:00 +01:00
Martin Pitt
e54dc6dd77 debian/tests/boot-smoke: Only check current boot for connection timeouts
Otherwise we'll catch some

    Failed to resolve group 'render': Connection timed out

messages that happen in earlier boots during VM setup, before the
"render" group is created.

Fixes https://github.com/systemd/systemd/issues/11875
2019-03-03 21:21:50 +01:00
Martin Pitt
d48f273d6a debian/tests/boot-smoke: Save complete journal artifact on failure
Gbp-Dch: Ignore
2019-03-03 12:12:40 +01:00
Martin Pitt
ca4674f900 autopkgtests: Replace obsolete $ADT_* variables
Use their $AUTOPKGTEST_* equivalents.

These were introduced in autopkgtest 4.0 (June 2016), and all our CI
systems use a much newer version.

Gbp-Dch: Short
2019-03-01 09:17:36 +01:00
Martin Pitt
6a9a7ec2bf debian/tests/boot-smoke: Create journal and udevdb artifacts on all failures 2019-03-01 09:13:15 +01:00
Martin Pitt
2ab793c735 debian/tests/boot-smoke: Create "render" system group
When running tests for upstream PRs, this test often fails with

    checking for connection timeouts
    systemd-udevd[1228]: Failed to resolve group 'render': Connection timed out

Which is not the kind of timeout the test is looking for. Create the
group in the test to avoid this.

We explicitly don't create the group in systemd.postinst as we revert
the patch that introduces the group into the udev rules.
2019-02-26 23:36:46 +01:00
Martin Pitt
b833092230 debian/tests/boot-smoke: More robust journal checking
Also fail the test if calling journalctl fails, and avoid calling it
twice. See https://github.com/systemd/systemd/pull/8032
2018-02-10 12:55:43 +01:00
Martin Pitt
39fc527be0 debian/tests/boot-smoke: Only run 5 iterations
20 iterations take about 45 minutes in our cloud environment, so dial that down
for now. It's simple enough to bump back once we actually run into a hard to
reproduce boot failure, but it has not happened in a long time.

Gbp-Dch: Short
2016-09-19 22:36:59 +02:00
Martin Pitt
a1bbdee842 debian/tests/smoke: Store udev db dump artifact on failure 2016-09-10 13:20:16 +02:00
Martin Pitt
4a5b0df050 debian/tests/boot-smoke: Configure dummy X.org driver
(like in the boot-and-services test). This should avoid lightdm randomly fail.

LP: #1571673
2016-04-20 09:00:34 +02:00
Martin Pitt
2c61cc9874 debian/tests/boot-smoke: Add some extra debugging if there are pending jobs after 10s
This should help to figure out why lightdm is sometimes "restarting". See
<https://launchpad.net/bugs/1571673>.
2016-04-18 17:31:18 +02:00
Martin Pitt
e9fade0af7 debian/tests/boot-smoke: Apply check for failed unmounts only to user systemd processes, i. e. not to pid 1
pid 1 sometimes fails to unmount with something like

  systemd[1]: Failed unmounting /run/user/108.
2015-10-14 09:43:21 +02:00
Martin Pitt
2e4ab375bf debian/tests/boot-smoke: Check for failed unmounts
This reproduces #801361 (but not in a minimal VM, just in a desktop one).
2015-10-09 11:51:10 +02:00
Michael Biebl
e05826cb0b Fix typo: persistant → persistent, thanks lintian 2015-06-18 15:36:21 +02:00
Martin Pitt
67bfdf266f debian/tests/boot-smoke: Allow 10 seconds for systemd jobs to settle down 2015-05-19 12:27:43 +02:00
Martin Pitt
bb8bab30b3 autopkgtests: Factorize out "assert.sh" utility functions
Use them in the tests for useful failure messages.
2015-02-24 16:00:22 +01:00
Martin Pitt
ee41f0f3b5 Make debian/tests/boot-smoke executable 2015-02-24 07:23:56 +01:00
Martin Pitt
75f8479087 Add "boot-smoke" autopkgtest: Test 20 successful reboots in a row
Also check that there are no connection timeouts or stalled jobs.

This reproduces the regression in LP: #1423811
2015-02-22 18:33:58 +01:00