]> git.ipfire.org Git - thirdparty/systemd.git/commit
test: make the shutdown routine a bit more "robust"
authorFrantisek Sumsal <frantisek@sumsal.cz>
Tue, 21 Jun 2022 08:20:12 +0000 (10:20 +0200)
committerFrantisek Sumsal <frantisek@sumsal.cz>
Tue, 21 Jun 2022 10:11:43 +0000 (12:11 +0200)
commit56e8ee55d58e38d47992ca6b5b6466fdb5be4781
treea772cbe46e5a4bd3f8fb5589cbdf370261b805d8
parent5309b56505dfccf9111cb5fe6461047725429e79
test: make the shutdown routine a bit more "robust"

Replace the call to the `end.service` with `systemctl poweroff`, since
it seems to cause issues no matter what `--job-mode=` is used:

```
[  129.070993] testsuite-21.sh[380]: ++ systemctl start --job-mode=flush end.service
[  129.154985] testsuite-21.sh[912]: Failed to start end.service: Transaction for end.service/start is destructive (sysinit.target has 'stop' job queued, but 'start' is included in transaction).
[  129.159636] testsuite-21.sh[912]: See system logs and 'systemctl status end.service' for details.
```

Also, add a "safety net" which bypasses the manager and does the
poweroff directly, since sometimes the D-Bus call performed by
`systemctl` might timeout (as the manager might be still processing data
from the fuzzing):

```
[  115.776778] sh[894]: + systemctl poweroff --no-block
[  166.164242] testsuite-21.sh[893]: Failed to start transient service unit: Connection timed out
[  166.269289] sh[894]: Call to PowerOff failed: Connection timed out
```
test/units/testsuite-21.sh