systemd-rfkill service times out when a new rfkill device is added
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
systemd (Ubuntu) |
Fix Released
|
High
|
Kleber Sacilotto de Souza | ||
Artful |
Fix Released
|
High
|
Unassigned |
Bug Description
[Impact]
The following issue was observed while running network-
-------
Nov 21 17:00:32 autopkgtest systemd[1]: Starting Load/Save RF Kill Switch Status...
Nov 21 17:01:02 autopkgtest systemd[1]: systemd-
Nov 21 17:01:02 autopkgtest systemd[1]: Failed to start Load/Save RF Kill Switch Status.
Nov 21 17:01:02 autopkgtest systemd[1]: systemd-
Nov 21 17:01:02 autopkgtest systemd[1]: systemd-
-------
This happens after the testcase inserts the fake-rfkill module (a module shipped with network-manager tests that registers a new fake device with the rfkill subsystem).
On Artful, it causes the network-manager autopkgtest killswitches-
[Fix]
The issue is fixed by the following systemd upstream patches:
-------
https:/
commit 8ec1a07998758f6
Author: S. Fan <email address hidden>
Date: Mon Jul 31 05:10:10 2017 -0500
rfkill: fix erroneous behavior when polling the udev monitor (#6489)
Comparing udev_device_
true. We need to check the device received from udev monitor instead.
Also, fd_wait_for_event() sometimes never exits. Better set a timeout
here.
-------
-------
https:/
commit c7f6ca9379279af
Author: Xiang Fan <email address hidden>
Date: Wed Aug 9 05:51:53 2017 -0500
rfkill: fix typo (#6574)
-------
With the fixes, the output from systemd-rfkill is:
-------
Nov 28 15:27:54 autopkgtest systemd[1]: Starting Load/Save RF Kill Switch Status...
Nov 28 15:27:59 autopkgtest systemd-
Nov 28 15:27:59 autopkgtest systemd[1]: Started Load/Save RF Kill Switch Status.
-------
The patches are needed to fix the ADT tests observed with Artful tests on ppc64el architecture:
https:/
[Test Case]
2.1. Download network-manager package source code
$ apt-get source network-manager
2.2. Run killswitches-
$ cd network-
$ sudo ./debian/
[Regression Potential]
Most of the network-manager and rfkill functionalities that can be affected by this change are tested by killswitches-
The only rfkill command that is not covered by the testcase is 'event', which listens to rfkill events and display them. I have run tests manually and verified that it's not affected by these changes. These are the outputs from the unpatched and patched systemd versions while running the killswitches-
systemd 234-2ubuntu12.1:
-------
$ sudo rfkill event
1513163787.877080: idx 3 type 1 op 0 soft 0 hard 0
1513163818.118695: idx 3 type 1 op 2 soft 1 hard 0
1513163818.222639: idx 3 type 1 op 2 soft 0 hard 0
1513163818.254778: idx 3 type 1 op 1 soft 0 hard 0
-------
systemd 234-2ubuntu12.2:
-------
$ sudo rfkill event
1513164121.690285: idx 0 type 1 op 0 soft 0 hard 0
1513164151.996227: idx 0 type 1 op 2 soft 1 hard 0
1513164152.114794: idx 0 type 1 op 2 soft 0 hard 0
1513164152.140536: idx 0 type 1 op 1 soft 0 hard 0
-------
Regression potential is also minimized by the fact that the fix has been applied some months ago on upstream github repo and it's being shipped with systemd on Bionic (systemd=
CVE References
description: | updated |
Changed in systemd (Ubuntu): | |
status: | New → In Progress |
importance: | Undecided → High |
assignee: | nobody → Kleber Sacilotto de Souza (kleber-souza) |
description: | updated |
Changed in systemd (Ubuntu Artful): | |
importance: | Undecided → High |
This is a debdiff for Artful applicable to systemd 234-2ubuntu12.1. This was built with pbuilder and tested in an Artful VM and the fix works as expected.