Upgrading Debian 12 Bookworm to Debian 13 Trixie

Hi all,

in case anyone is interested, here’s a short step-by-step tutorial to upgrade Debian Bookworm to Debian Trixie.

DISCLAIMER
While Debian officially supports in-place upgrades from Bookworm to Trixie, and the process is well-documented, a stable and fresh install of Debian Trixie followed by a restore of your openHAB backup is the safer and more robust approach.

1. Make Sure the System Is Up to Date

Before upgrading, update and upgrade all existing packages:

sudo apt update
sudo apt full-upgrade

2. Edit sources.list for Debian Trixie

Change all references from bookworm to trixie in:

/etc/apt/sources.list

Also update any files in:

/etc/apt/sources.list.d/

For example, I updated the raspi.list file

image

3. Refresh Package Index

Once sources are updated, run:

sudo apt update

4. Upgrade to Debian 13 (Trixie)

Now perform the full upgrade with this command:

sudo apt full-upgrade -y \
  -o Dpkg::Options::="--force-confdef" \
  -o Dpkg::Options::="--force-confnew" \
  --purge --auto-remove rpd-wayland-all+ rpd-x-all+

:warning: This command must be typed exactly as shown. Make particular note of the plus signs at the end of rpd-wayland-all and rpd-x-all.

For trixie, the raspberrypi-ui-mods package has been obsoleted; this has been replaced with a number of new packages containing configuration information that make the configuration of an image more modular; among other things, these two new packages contain the configuration that used to be in ui-mods, and a trixie image will not be correctly configured without them.)

5. Reboot

After the upgrade completes, reboot your system.

[OPTIONAL] Install fastfetch and Verify

Debian 13 includes fastfetch, a modern and faster alternative to neofetch.

Install it with:

sudo apt install fastfetch

Final Thoughts

While Bookworm is EOL in 2028, Trixie is currently the only distro that comes with openjdk-21-jdk (21.0.8+9-1). This upgrade went smoothly on my end.

Please do let me know if anyone experiences issues upgrading from Debian 12 to 13.

3 Likes

Oh, I like that it comes with fastfetch now. That will simplify my Ansible scripts significantly.

But it’s worth noting that the official Raspberri Pi OS Trixie isn’t out yet so be cautious.

Yep. I would not recommend to dist-upgrade and definitely not so if on Raspberry.

Unlike openHABian (that uses bookworm and Temurin Java), that OS-Java combo is totally untested with openHAB.

This combo is used in the openHAB Debian Docker container.

1 Like