systemd unit tests need updates for Linux 5.8 and later

Bug #1891527 reported by Seth Forshee
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
systemd
Fix Released
Unknown
systemd (Ubuntu)
Fix Released
Undecided
Balint Reczey

Bug Description

Linux 5.8 allows unprivileged creation of whiteout devices, causing a couple of test failures in systemd:

====== test-fs-util =======
/* test_chase_symlinks */
/* test_unlink_noerrno */
/* test_readlink_and_make_absolute */
/* test_var_tmp */
/* test_dot_or_dot_dot */
/* test_access_fd */
/* test_touch_file */
Assertion 'mknod(a, 0775 | S_IFBLK, makedev(0, 0)) >= 0' failed at src/test/test-fs-util.c:637, function test_touch_file(). Aborting.
FAIL: test-fs-util (code: 134)
...
====== test-stat-util =======
Assertion 'stat(path, &st) >= 0' failed at src/test/test-stat-util.c:126, function test_device_path_make_canonical_one(). Aborting.
FAIL: test-stat-util (code: 134)

test-fs-util succeeds in making a character device with major/minor 0,0, and thus assumes it will be able to create other devices, but it cannot.

test-stat-util assumes that because /run/systemd/inaccessible/chr exists /run/systemd/inaccessible/blk should also exist, but it does not for the same reason.

Revision history for this message
Seth Forshee (sforshee) wrote :
Changed in systemd:
status: Unknown → New
Revision history for this message
Seth Forshee (sforshee) wrote :
Changed in systemd:
status: New → Fix Released
Balint Reczey (rbalint)
Changed in systemd (Ubuntu):
assignee: nobody → Balint Reczey (rbalint)
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (3.4 KiB)

This bug was fixed in the package systemd - 246.2-1ubuntu1

---------------
systemd (246.2-1ubuntu1) groovy; urgency=medium

  * Merge from Debian unstable
  * Refresh patches
  * test: accept that char device 0/0 can now be created witout privileges.
    This fixes tests with Linux 5.8 and later (LP: #1891527)
    Files:
    - debian/patches/debian/Add-env-variable-for-machine-ID-path.patch
    - debian/patches/test-accept-that-char-device-0-0-can-now-be-created-witou.patch
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=57909a0fa4999ba9ff918cfe6bb3fa53c230dd36
  * debian/tests/systemd-fsckd: Fail plymouth-start with overriding ExecStart=
    The 'process-killer' stopped working with plymouth 0.9.5 (LP: #1886886)
    File: debian/tests/systemd-fsckd
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=efcc25b6011f23b9f90841f4ca0ee29ee674157f
  * cherry-pick from stable: network: only process non-error message
    File: debian/patches/network-only-process-non-error-message.patch
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=dc97e3f5330ae64909ef640ad1ac401374f18c16
  * network: wait for previous address removal before configuring static addresses.
    Fixes systemd-networkd to establish connection after resume from suspend
    Files:
    - debian/patches/network-wait-for-previous-address-removal-before-configur.patch
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=31390403bc000892ada9cb0cbedb198dd83fe7a2
  * network: do not fail if UseMTU=yes on DHCP lease lost
    File: debian/patches/network-do-not-fail-if-UseMTU-yes-on-DHCP-lease-lost.patch
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=21c23966e8dc5fd0858664a5b89d6a9460c41f61
  * debian/systemd.postinst: Restart systemd-networkd.socket on incompatible change
    (Closes: #968589) (LP: #1891716)
    File: debian/systemd.postinst
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=e144a644488c6ff52c2bb7cee71f50aa95c4efd8
  * debian/tests/control: Mark systemd-fsckd test as flaky.
    It is flaky on Ubuntu CI infrastructure (LP: #1892358)
    File: debian/tests/control
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=8c55289624c6f44beb2c5bbae78aabc074d36b1a

systemd (246.2-1) unstable; urgency=medium

  * New upstream version 246.2
  * Remove resolvconf.conf drop-in, resolved integration moved to resolvconf
    package
  * Rebase patches
  * Add versioned Breaks against resolvconf (<< 1.83~) to systemd.
    The PathExists= directive was changed in v246 to match the documented
    behaviour but now causes resolvconf-pull-resolved.service to be
    continuously triggered by resolvconf-pull-resolved.path.
    This requires a fix in the resolvconf package, see #968015.
    (Closes: #967906)
  * Keep journal files compatible with older versions.
    Disable the KEYED-HASH journal feature by default and keep LZ4 (instead
    of ZSTD) as default compression for new journal files. Otherwise journal
    files are incompatible and can't be read by older journalctl
    implementation...

Read more...

Changed in systemd (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.