Upgrading to systemd-utils and resolving systemd-tmpfiles soft blocking systemd-utils

main menu
News migrating to systemd-utils

Recently a new Gentoo package was added – sys-apps/systemd-utils, which should replace three separate packages sys-apps/systemd-tmpfiles, sys-boot/systemd-boot and sys-fs/udev. As the sys-fs/udev is one of the core packages in the OpenRC world and it can trigger multiple blocking errors and dependency problems.
The sys-apps/systemd-utils has three USE variables for the three replacing packages – udev, boot, and tmpfiles, so the user might add them in make.conf file.
It’s worth noting when upgrading to the sys-apps/systemd-utils, the sys-apps/systemd-tmpfiles and sys-boot/systemd-boot will be removed, but sys-fs/udev is staying in the system with version sys-fs/udev-250 and above. The sys-fs/udev-250 would always pull in sys-apps/systemd-utils[udev] as a dependency. Despite the names including systemd, these packages do not depend on systemd and are meant to be used in OpenRC system.
There is Gentoo news about this upgrade and it can be read with eselect. Check out the article ending for more information.
Here is what a blocking could look like:

root@srv ~ # emerge -vau world
......
......
[ebuild     U  ] dev-lang/php-8.0.27:8.0::gentoo [8.0.25:8.0::gentoo] USE="acl bcmath berkdb bzip2 calendar cli ctype curl enchant exif fileinfo filter flatfile fpm ftp gd gdbm gmp iconv imap intl ipv6 jit mhash mysql mysqli nls opcache pcntl pdo phar posix readline session session-mm sharedmem simplexml soap sockets sqlite ssl tidy tokenizer truetype unicode xml xmlreader xmlwriter xslt zip zlib -apache2 -apparmor -argon2 -cdb -cgi -cjk -coverage -debug -embed -ffi -firebird -inifile -iodbc -kerberos -ldap -ldap-sasl -libedit -lmdb -mssql -oci8-instant-client -odbc -phpdbg -postgres -qdbm (-selinux) -snmp -sodium -spell -systemd -sysvipc -test -threads -tokyocabinet -webp -xpm" 10549 KiB
[ebuild     UD ] sys-apps/man-pages-posix-2013a::gentoo [2017a::gentoo] 909 KiB
[ebuild     U  ] sys-apps/openrc-0.46::gentoo [0.45.2-r1::gentoo] USE="ncurses netifrc pam unicode -audit -bash -debug -newnet (-selinux) -sysv-utils" 242 KiB
[blocks B      ] sys-fs/eudev ("sys-fs/eudev" is soft blocking sys-apps/systemd-utils-251.10-r1)
[blocks B      ] sys-apps/systemd-utils[udev] ("sys-apps/systemd-utils[udev]" is soft blocking sys-fs/eudev-3.2.11-r3)

Total: 113 packages (97 upgrades, 1 downgrade, 15 new), Size of downloads: 554077 KiB
Conflict: 3 blocks (2 unsatisfied)

 * Error: The above package list contains packages which cannot be
 * installed at the same time on the same system.

  (sys-fs/eudev-3.2.11-r3:0/0::gentoo, installed) pulled in by
    sys-fs/eudev required by @selected 

  (sys-apps/systemd-utils-251.10-r1:0/0::gentoo, ebuild scheduled for merge) pulled in by
    sys-apps/systemd-utils[tmpfiles] required by (sys-apps/systemd-tmpfiles-250:0/0::gentoo, ebuild scheduled for merge) USE="" ABI_X86="(64)"
    sys-apps/systemd-utils[tmpfiles] required by (virtual/tmpfiles-0-r3:0/0::gentoo, installed) USE="" ABI_X86="(64)"
    sys-apps/systemd-utils[udev] required by (virtual/udev-217-r5:0/0::gentoo, installed) USE="" ABI_X86="(64)"


For more information about Blocked Packages, please refer to the following
section of the Gentoo Linux x86 Handbook (architecture is irrelevant):

https://wiki.gentoo.org/wiki/Handbook:X86/Working/Portage#Blocked_packages
root@srv ~ # emerge -va sys-apps/systemd-utils


These are the packages that would be merged, in order:

Calculating dependencies... done!
Dependency resolution took 0.84 s.

[ebuild  N     ] acct-group/audio-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/cdrom-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/dialout-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/disk-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/kmem-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/lp-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/sgx-0::gentoo  0 KiB
[ebuild  N     ] acct-group/tape-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/tty-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/video-0-r1::gentoo  0 KiB
[ebuild  N     ] sys-apps/systemd-utils-251.10-r1::gentoo  USE="acl kmod (split-usr) tmpfiles udev -boot (-selinux) -sysusers -test" ABI_X86="(64) -32 (-x32)" 11194 KiB
[blocks B      ] <sys-apps/systemd-tmpfiles-250 ("<sys-apps/systemd-tmpfiles-250" is soft blocking sys-apps/systemd-utils-251.10-r1)
[blocks B      ] sys-fs/eudev ("sys-fs/eudev" is soft blocking sys-apps/systemd-utils-251.10-r1)
[blocks B      ] sys-apps/systemd-utils[udev] ("sys-apps/systemd-utils[udev]" is soft blocking sys-fs/eudev-3.2.11-r3)

Total: 11 packages (11 new), Size of downloads: 11194 KiB
Conflict: 3 blocks (3 unsatisfied)

 * Error: The above package list contains packages which cannot be
 * installed at the same time on the same system.

  (sys-apps/systemd-tmpfiles-249.9:0/0::gentoo, installed) pulled in by
    sys-apps/systemd-tmpfiles required by @selected 

  (sys-apps/systemd-utils-251.10-r1:0/0::gentoo, ebuild scheduled for merge) pulled in by
    sys-apps/systemd-utils

  (sys-fs/eudev-3.2.11-r3:0/0::gentoo, installed) pulled in by
    sys-fs/eudev required by @selected 


For more information about Blocked Packages, please refer to the following
section of the Gentoo Linux x86 Handbook (architecture is irrelevant):

https://wiki.gentoo.org/wiki/Handbook:X86/Working/Portage#Blocked_packages

A screenshot from the command line, which is colored properly.

main menu
Unresolved Soft blocking tmpfiles and eudev

To solve the soft blocking, first, deselect the old packages, which are soft blocking the sys-apps/systemd-utils. In the above example, the problematic packages are sys-fs/eudev and sys-apps/systemd-tmpfiles. Deselect the packages and try to build only sys-apps/systemd-utils:

root@srv ~ # emerge --deselect sys-fs/eudev sys-apps/systemd-tmpfiles
>>> Removing sys-apps/systemd-tmpfiles from "world" favorites file...
>>> Removing sys-fs/eudev from "world" favorites file...

And then emerge command should report the two packages will be removed when the sys-apps/systemd-utils would be installed.

root@srv ~ # emerge -va sys-apps/systemd-utils udev

These are the packages that would be merged, in order:

Calculating dependencies... done!
Dependency resolution took 1.98 s.

[ebuild  N     ] acct-group/audio-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/cdrom-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/dialout-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/disk-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/kmem-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/lp-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/sgx-0::gentoo  0 KiB
[ebuild  N     ] acct-group/tape-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/tty-0-r1::gentoo  0 KiB
[ebuild  N     ] acct-group/video-0-r1::gentoo  0 KiB
[ebuild  N     ] sys-apps/systemd-utils-251.10-r1::gentoo  USE="acl kmod (split-usr) tmpfiles udev -boot (-selinux) -sysusers -test" ABI_X86="(64) -32 (-x32)" 11194 KiB
[uninstall     ] sys-apps/systemd-tmpfiles-249.9::gentoo  USE="(-selinux) -test" 
[blocks b      ] <sys-apps/systemd-tmpfiles-250 ("<sys-apps/systemd-tmpfiles-250" is soft blocking sys-apps/systemd-utils-251.10-r1)
[uninstall     ] sys-fs/eudev-3.2.11-r3::gentoo  USE="kmod (split-usr) -introspection -rule-generator (-selinux) -static-libs -test" ABI_X86="(64) -32 (-x32)" 
[blocks b      ] sys-apps/systemd-utils[udev] ("sys-apps/systemd-utils[udev]" is soft blocking sys-fs/eudev-3.2.11-r3)
[blocks b      ] sys-fs/eudev ("sys-fs/eudev" is soft blocking sys-apps/systemd-utils-251.10-r1)

Total: 11 packages (11 new, 2 uninstalls), Size of downloads: 11194 KiB
Conflict: 3 blocks (all satisfied)

Would you like to merge these packages? [Yes/No] yes

>>> Verifying ebuild manifests

>>> Running pre-merge checks for acct-group/audio-0-r1

>>> Running pre-merge checks for acct-group/cdrom-0-r1
......
......

The blocks are not red, but only the uninstalls. Blocks in light blue are resolved.

main menu
Resolved soft blocking tmpfiles and eudev

The emerge command reports 2 uninstalls and 11 new and the upgrade may proceed just type “yes”.
Deselecting old packages may solve very complicated problems in the dependency tree. More information for upgrading Gentoo and blocking or masked packages here – Gentoo update tips when updating packages with blocks and masked files

Showing the Gentoo news about systemd-utils

List the news, find the number of the news and read it. On different systems, the numbering might be different!

root@srv ~ # eselect news list
News items:
  [1]   N  2016-06-23  (2016-06-23-l10n-use_expand - removed?)
  [2]   N  2018-08-07  Migration required for OpenSSH with LDAP
  [3]   N  2019-05-23  Change of ACCEPT_LICENSE default
  [4]   N  2020-06-23  sys-libs/pam-1.4.0 upgrade
  [5]   N  2021-01-30  New OpenRC Display Manager Initializer Scripts
  [6]   N  2021-01-30  (2021-01-30-python-preference-to-follow-python-targets - removed?)
  [7]   N  2021-07-15  systemd-tmpfiles replaces deprecated opentmpfiles
  [8]   N  2021-07-20  Perl 5.34 upgrade now stable
  [9]   N  2021-07-23  (2021-07-23-libxcrypt-migration - removed?)
  [10]  N  2021-08-24  eudev retirement on 2022-01-01
  [11]  N  2021-09-24  busybox removal from system set
  [12]  N  2021-09-29  Possible failure to preserve libraries
  [13]  N  2021-10-08  OpenSSH RSA SHA-1 signatures
  [14]  N  2021-10-17  dev-libs/openssl USE=bindist removal
  [15]  N  2021-10-18  migrating from glibc[crypt] to libxcrypt in stable
  [16]  N  2021-10-24  netifrc DHCP client
  [17]     2022-04-19  Migration to sys-apps/systemd-utils
  [18]  N  2022-06-13  Python 3.10 to become the default on 2022-07-01
  [19]  N  2022-11-21  systemd-tmpfiles --clean enabled by default
  [20]  N  2022-12-27  Introduction of app-alternatives ebuilds
root@srv ~ # eselect news read 17
2022-04-19-systemd-utils
  Title                     Migration to sys-apps/systemd-utils
  Author                    Mike Gilbert <floppym@gentoo.org>
  Posted                    2022-04-19
  Revision                  1

The sys-apps/systemd-utils package was recently added to the gentoo
repository. This replaces sys-apps/systemd-tmpfiles,
sys-boot/systemd-boot, and sys-fs/udev with a single package, and is
for OpenRC users. It does not depend on sys-apps/systemd and contains
the same exact components as the split packages.

USE flags are provided to allow each component to be enabled
or disabled. This change was made to significantly ease maintenance of tools
split out from systemd.

When upgrading to sys-apps/systemd-tmpfiles-250,
sys-apps/systemd-utils[tmpfiles] will be pulled in as a dependency.

When upgrading to sys-boot/systemd-boot-250,
sys-apps/systemd-utils[boot] will be pulled in as a dependency.

When upgrading to sys-fs/udev-250, sys-apps/systemd-utils[udev] will be
pulled in as a dependency.

At a later date, sys-apps/systemd-tmpfiles, sys-boot/systemd-boot, and
sys-fs/udev will be masked for removal once a suitable version of
sys-apps/systemd-utils has been marked stable and sufficient time has
been provided for users to migrate.

Possible problems when upgrading:

1. If sys-fs/eudev is present in the world file (@selected), emerge will
   abort the upgrade with a unsolvable blocker error. To resolve this,
   either remove sys-fs/eudev from the world file
   (emerge --deselect sys-fs/eudev), or disable the 'udev' USE flag for
   sys-apps/systemd-utils.

2. The 'boot' USE flag on sys-apps/systemd-utils is disabled by default.
   Users migrating from sys-boot/systemd-boot will need to enable the
   'boot' USE flag (in package.use) to continue receiving updates.

3. If you have package.use entries for any of sys-apps/systemd-tmpfiles,
   sys-boot/systemd-boot, or sys-fs/udev, please update the relevant lines
   to refer to sys-apps/systemd-utils instead. This might include
   ABI_X86_32 for some users!

Leave a Reply

Your email address will not be published. Required fields are marked *