Upgrade Bullseye to Bookworm, and getting of rid of systemd?

Thorsten Glaser t.glaser at tarent.de
Thu Jun 22 19:05:06 BST 2023

On Thu, 22 Jun 2023, Mason Loring Bliss wrote:

>    apt --purge install sysvinit-core libnss-systemd-

Why don’t you remove libnss-systemd *after* the reboot? Seems safer.

>    <reboot>
>    apt --purge install libelogind0 systemd-

Note that a switch to libelogind0 is not necessary unless you either
use elogind, which I can only disrecommend because it changes the
system behaviour, or for ideological reasons. Keeping libsystemd0 is
also workable.

>    avahi-daemon:any


For reference, mine are (in ascending order of strictness):

$ cat /etc/apt/preferences.d/prevent-systemd-running 
Package: kdbus-dkms live-config-systemd systemd-cron systemd-sysv systemd-ui
Pin: version *
Pin-Priority: -1
$ cat /etc/apt/preferences.d/prevent-systemd-installed 
Package: kdbus-dkms live-config-systemd systemd systemd-cron systemd-sysv systemd-ui
Pin: version *
Pin-Priority: -1
$ cat /etc/apt/preferences.d/prevent-systemd-completely 
Package: kdbus-dkms libpam-systemd live-config-systemd python-systemd python3-systemd systemd systemd-cron systemd-shim systemd-sysv systemd-ui
Pin: version *
Pin-Priority: -1

You may also want:

$ cat /etc/apt/preferences.d/prevent-libelogind-removal 
Package: libsystemd0
Pin: version *
Pin-Priority: -1

Alternatively, I use a package like…

 Package: logind-considered-harmful                                                                              
 Version: 85                                                                                                     
 Section: metapackages                                                                                           
 Priority: optional                                                                                              
 Architecture: all                                                                                               
 Multi-Arch: foreign                                                                                             
 Recommends: prevent-libelogind-removal                                                                          
 Enhances: policykit-1, udisks2-without-systemd                                                                  
 Conflicts: logind, default-logind, elogind, libpam-elogind, libpam-systemd                                      
 Provides: logind                                                                                                

… that doesn’t actually *contain* a logind implementation but provides
it so the package dependencies on that thing are “fulfilled” which is
not a problem if you don’t actually use the logind functionality.

>    src:usrmerge:any

I highly doubt that src: prefix works. And don’t do that for bookworm
anyway. One of the packages where the above-mentioned preferences.d
files come from has had to accept that particular enshittification:

 Package: prevent-systemd-completely
 Depends: prevent-usrmove | base-files (>> 12), […]

(bullseye has base-files 11.1+*, bookworm has 12.4, trixie/sid has 13)

Infrastrukturexperte • tarent solutions GmbH
Am Dickobskreuz 10, D-53121 Bonn • http://www.tarent.de/
Telephon +49 228 54881-393 • Fax: +49 228 54881-235
HRB AG Bonn 5168 • USt-ID (VAT): DE122264941
Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg

/⁀\ The UTF-8 Ribbon
╲ ╱ Campaign against      Mit dem tarent-Newsletter nichts mehr verpassen:
 ╳  HTML eMail! Also,     https://www.tarent.de/newsletter
╱ ╲ header encryption!

More information about the Debian-init-diversity mailing list