Devuan Upgrade: 4 to 5 Daedalus

Table of contents

Summary Summary

Devuan (opens in a new tab) is a fork of Debian (opens in a new tab) GNU (opens in a new tab)+Linux (opens in a new tab) without systemd (opens in a new tab).

Its new major version, 5 - Daedalus, was released (opens in a new tab) 🎉 this August, on 2023-08-14. Nearly two years had passed since was the previous (opens in a new tab) 4 - Chimaera. It is based on Debian 12 - Bookworm (opens in a new tab) with Linux 6.1 (LTS) ☺️

I have recently upgraded my workstations, helped by the official guide “Upgrade to Daedalus (opens in a new tab)”. This post is the record.

Environment Environment

Basic Steps Basic Steps

The first and also primary step is to replace package repositories (opens in a new tab) of Chimaera with Daudalus':

console
# nvim /etc/apt/sources.list

Before actual update, confirm your shell is independent on python. It is important when you use fish (opens in a new tab):

console
$ # (optional)
$ bash

Run the packages update. It will take long to update many packages, and also ask you a few questions:

console
# apt update

Stop xscreensaver (opens in a new tab) before upgrade if it is running:

console
$ killall xscreensaver

Run the distribution update:

console
# apt dist-upgrade

Finally, clean up:

console
# apt autoremove --purge
# apt autoclean

The below is the description with both result and questions printed out at each step.


Description Description

All doas (opens in a new tab) from OpenBSD’s (opens in a new tab) can be replaced with sudo (opens in a new tab).

Confirm compatibility Confirm compatibility

You should read Devuan Daedalus Release Notes (opens in a new tab) before start.

Replace repos Replace repos

Create backup for the previous version as needed with command-lines such as:

console
$ # (optional)
$ doas cp -p /etc/apt/sources.list /etc/apt/sources.list.bk-chimaera

Let’s move to Daudauls':

console
$ doas nvim /etc/apt/sources.list

by replacing chimaera with daedalus:

diff
< deb http://deb.devuan.org/merged chimaera main non-free contrib
< deb-src http://deb.devuan.org/merged chimaera main non-free contrib
> deb http://deb.devuan.org/merged daedalus main non-free contrib
> deb-src http://deb.devuan.org/merged daedalus main non-free contrib
< deb http://pkgmaster.devuan.org/merged chimaera-security main contrib non-free
< deb-src http://pkgmaster.devuan.org/merged chimaera-security main contrib non-free
> deb http://pkgmaster.devuan.org/merged daedalus-security main contrib non-free
> deb-src http://pkgmaster.devuan.org/merged daedalus-security main contrib non-free
< deb http://deb.devuan.org/merged chimaera-updates main contrib non-free
< deb-src http://deb.devuan.org/merged chimaera-updates main contrib non-free
> deb http://deb.devuan.org/merged daedalus-updates main contrib non-free
> deb-src http://deb.devuan.org/merged daedalus-updates main contrib non-free

Update packages Update packages

We are now ready. Run the update for packages:

console
$ doas apt update

It will print out as below and also ask you the first question:

console
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
  (...)
Use 'apt autoremove' to remove them.
The following NEW packages will be installed:
  (...)
The following packages have been kept back:
  (...)
The following packages will be upgraded:
  (...)
1595 upgraded, 233 newly installed, 0 to remove and 117 not upgraded.
Need to get 1587 MB of archives.
After this operation, 2563 MB of additional disk space will be used.
Do you want to continue? [Y/n] y

Then it will proceed as below:

console
Get:1 (...)
(...)
Fetched 1533 MB in 2min 58s (8612 kB/s)                                                              
Reading changelogs...

The changelogs will be shown:

console
apt-listchanges: News
---------------------

adduser (3.130) unstable; urgency=low

  deluser's --no-preserve-root option is deprecated, and it will be
  (...)

Then it will continue:

console
Reading changelogs... Done
Extracting templates from packages: 100%
Preconfiguring packages ...

The additional questions on console configuration will be shown:

devuan-upgrade-daedalus-console-01

devuan-upgrade-daedalus-console-02

They are, of course, up to you. In my case, the default was chosen at each.

Then it will continue:

Installing new version of config file /etc/debian_version ...
Installing new version of config file /etc/devuan_version ...
Installing new version of config file /etc/issue ...
Installing new version of config file /etc/issue.net ...
(...)
Setting up libc6:amd64 (2.36-9+deb12u1) ...

You will be asked:

devuan-upgrade-daedalus-libc-01

The additional question below will be sometimes given:

devuan-upgrade-daedalus-libc-02

Then it will proceed:

console
Restarting services possibly affected by the upgrade:
  cups: restarting...done.
  cron: restarting...done.

Services restarted successfully.
(...)
Setting up devuan-keyring (2023.05.28) ...

There are a few questions left.

console
Setting up devuan-keyring (2023.05.28) ...

Configuration file '/etc/apt/trusted.gpg.d/devuan-keyring-2016-archive.gpg'
 ==> File on system created by you or by a script.
 ==> File also in package provided by package maintainer.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** devuan-keyring-2016-archive.gpg (Y/I/N/O/D/Z) [default=N] ? Y

I chose to overwrite it as above. Then it will continue:

console
(...)
Setting up cups-ipp-utils (2.4.2-3+deb12u1) ...
Setting up slim (1.4.0-0devuan2) ...
Installing new version of config file /etc/init.d/slim ...

Then another question will be shown:

console
Configuration file '/etc/slim.conf'
 ==> Modified (by you or by a script) since installation.
 ==> Package distributor has shipped an updated version.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** slim.conf (Y/I/N/O/D/Z) [default=N] ? Y

I did, too.

console
Removing obsolete conffile /etc/init.d/lvm2 ...
Removing obsolete conffile /etc/init.d/lvm2-lvmpolld ...
Setting up grub-efi-amd64 (2.06-13) ...
Replacing config file /etc/default/grub with new version

The final question will be shown:

devuan-upgrade-daedalus-grub-01

I made it cleaned up. Again, they are up to you.

The rest will be automatic.

console
aspell-autobuildhash: processing: en [en_US-wo_accents-only].
Processing triggers for sgml-base (1.31) ...
Processing triggers for ca-certificates (20230311) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...
done.
Processing triggers for libvlc-bin:amd64 (3.0.18-2) ...
Processing triggers for initramfs-tools (0.142) ...
update-initramfs: Generating /boot/initrd.img-6.1.0-11-amd64
Processing triggers for dbus (1.14.6-1devuan1) ...
Processing triggers for libgdk-pixbuf-2.0-0:amd64 (2.42.10+dfsg-1+b1) ...
Processing triggers for shim-signed:amd64 (1.39+15.7-1) ...
Processing triggers for ca-certificates-java (20230103) ...
done.

Note: Occasional problem occurred by shell dependent on Python Note: Occasional problem occurred by shell dependent on Python

When the shell used is fish, apt update above will bring the error in console like below:

console
/usr/share/fish/functions/prompt_pwd.fish (line 41): Invalid index value
                set full $all[2..]
                                 ^
in function 'prompt_pwd'
	called on line 1 of file /usr/share/fish/functions/fish_prompt.fish
in command substitution
	called on line 33 of file /usr/share/fish/functions/fish_prompt.fish
in function 'fish_prompt'
in command substitution
/usr/share/fish/functions/fish_git_prompt.fish (line 173): $(...) is not supported. In fish, please use '(uname)'.
if string match -q Darwin -- "$(uname)" && string match -q /usr/bin/git -- "$(command -s git)" && type -q xcode-select && type -q xcrun
                              ^
from sourcing file /usr/share/fish/functions/fish_git_prompt.fish
	called on line 1 of file /usr/share/fish/functions/fish_vcs_prompt.fish
in command substitution
	called on line 4 of file /usr/share/fish/functions/fish_vcs_prompt.fish
in function 'fish_vcs_prompt'
	called on line 1 of file /usr/share/fish/functions/fish_prompt.fish
in command substitution
	called on line 33 of file /usr/share/fish/functions/fish_prompt.fish
in function 'fish_prompt'
in command substitution
source: Error while reading file '/usr/share/fish/functions/fish_git_prompt.fish'
/usr/share/fish/functions/prompt_pwd.fish (line 41): Invalid index value
                set full $all[2..]
                                 ^
in function 'prompt_pwd' with arguments '-d 1 -D 1'
	called on line 1 of file /usr/share/fish/functions/fish_title.fish
in command substitution
	called on line 18 of file /usr/share/fish/functions/fish_title.fish
in function 'fish_title'
in command substitution

Even with them, it seemed to be able to complete the upgrade. However, I don’t know it was perfect or not.

Stop xscreensaver if running Stop xscreensaver if running

Run:

console
$ killall xscreensaver

Update distro Update distro

Next, run the command-line:

console
$ doas apt dist-upgrade

The process is much simpler than the packages’. It will print out like:

console
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
  (...)
Use 'apt autoremove' to remove them.
The following packages will be REMOVED:
  (...)
The following NEW packages will be installed:
  (...)
The following packages will be upgraded:
  (...)
115 upgraded, 54 newly installed, 14 to remove and 0 not upgraded.
Need to get 196 MB of archives.
After this operation, 149 MB of additional disk space will be used.
Do you want to continue? [Y/n] y

And it will finish without any question:

console
Get:1 (...)
(...)
Processing triggers for eudev (3.2.12-1) ...
Setting up libgnustep-base1.28 (1.28.1+really1.28.0-5) ...
Setting up gnustep-base-runtime (1.28.1+really1.28.0-5) ...
Setting up unar (1.10.7+ds1+really1.10.1-2+b2) ...
Processing triggers for libc-bin (2.36-9+deb12u1) ...

Clean up Clean up

Run autoremove Run autoremove

console
$ doas apt autoremove --purge

It will print out:

console
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
  exfat-fuse* golang-github-containernetworking-plugin-dnsname* libaom0* libavcodec58*
  libavdevice58* libavfilter7* libavformat58* libavutil56* libcmis-0.5-5v5* libcodec2-0.9*
  libdav1d4* libextutils-pkgconfig-perl* libgs9-common* libicu67* libidn11* libilmbase25*
  libldap-2.4-2* libmpdec3* libnautilus-extension1a* libneon27-gnutls* libopenexr25*
  liborcus-0.16-0* liborcus-parser-0.16-0* libperl5.32* libpoppler102* libpostproc55* libpython3.9*
  libpython3.9-dev* libpython3.9-minimal* libpython3.9-stdlib* libqrcodegencpp1* libsrt1.4-gnutls*
  libswresample3* libswscale5* libtiff5* libvpx6* libwebp6* libwmf0.2-7* libx264-160* libx265-192*
  perl-modules-5.32* python3-ldb* python3-talloc* python3.9* python3.9-dev* python3.9-minimal* (...)
0 upgraded, 0 newly installed, 47 to remove and 0 not upgraded.
After this operation, 210 MB disk space will be freed.
Do you want to continue? [Y/n] y

And finish:

console
(...)
Unlinking and removing bytecode for runtime python3.9
(...)
Processing triggers for desktop-file-utils (0.26-1) ...
(Reading database ... 201030 files and directories currently installed.)
Purging configuration files for libpython3.9-minimal:amd64 (3.9.2-1) ...
Purging configuration files for python3.9-minimal (3.9.2-1) ...

Run autoclean Run autoclean

console
$ doas apt autoclean

It will soon finish:

console
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Del libavdevice58 7:4.3.6-0+deb11u1 [128 kB]
(...)
Del libtirpc-dev 1.3.1-1+deb11u1 [191 kB]

Additional configuration (Optional) Additional configuration (Optional)

For example, you may want to modify /etc/default/grub. You will apply it by running:

console
$ doas nvim /usr/sbin/update-grub

It will print out like below:

console
Generating grub configuration file ...
Found background image: splash.png
Found linux image: /boot/vmlinuz-6.1.0-11-amd64
Found initrd image: /boot/initrd.img-6.1.0-11-amd64
Found linux image: /boot/vmlinuz-5.10.0-23-amd64
Found initrd image: /boot/initrd.img-5.10.0-23-amd64
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
done

Restart machine (Optional) Restart machine (Optional)

Hope you find new fun 🌄


Conclusion Conclusion

You may confirm the updated with:

console
$ uname --all
Linux (...) 6.1.0-11-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.38-4 (2023-08-08) x86_64 GNU/Linux

Well, the next Devuan project has already started with the codename “Excalibur” (🇪). I’m looking forward to meeting them while spending happy time with them ⛵

More on: Configure and secure a server

Scqr [secureal]

Scqr [secureal]: the engineering practice of Reflerd Inc. (opens in a new tab)

Comments and feedback are welcome.