Last active
May 2, 2026 14:27
-
-
Save jauderho/5f73f16cac28669e56608be14c41006c to your computer and use it in GitHub Desktop.
HOWTO: Upgrade Raspberry Pi OS from Bookworm to Trixie
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### WARNING: READ CAREFULLY BEFORE ATTEMPTING ### | |
| # | |
| # Officially, this is not recommended. YMMV | |
| # https://www.raspberrypi.com/news/bookworm-the-new-version-of-raspberry-pi-os/ | |
| # | |
| # This mostly works if you are on 64bit. You are on your own if you are on 32bit or mixed 64/32bit | |
| # | |
| # Credit to anfractuosity and fgimenezm for figuring out additional details for kernels | |
| # | |
| # Make sure everything is up-to-date | |
| sudo apt-get -y update && sudo DEBIAN_FRONTEND=noninteractive apt-get -y dist-upgrade | |
| # Point to bookworm repos instead | |
| sudo sed -i -e 's/bookworm/trixie/g' /etc/apt/sources.list | |
| sudo sed -i -e 's/bookworm/trixie/g' /etc/apt/sources.list.d/raspi.list | |
| # Contents of /etc/apt/sources.list | |
| deb http://deb.debian.org/debian trixie main contrib non-free non-free-firmware | |
| deb http://security.debian.org/debian-security trixie-security main contrib non-free non-free-firmware | |
| deb http://deb.debian.org/debian trixie-updates main contrib non-free non-free-firmware | |
| # Uncomment deb-src lines below then 'apt-get update' to enable 'apt-get source' | |
| #deb-src http://deb.debian.org/debian trixie main contrib non-free | |
| #deb-src http://security.debian.org/debian-security trixie-security main contrib non-free | |
| #deb-src http://deb.debian.org/debian trixie-updates main contrib non-free | |
| # Contents of /etc/apt/sources.list.d/raspi.list | |
| deb http://archive.raspberrypi.org/debian/ trixie main | |
| # Uncomment line below then 'apt-get update' to enable 'apt-get source' | |
| #deb-src http://archive.raspberrypi.org/debian/ trixie main | |
| # Do actual update. See also https://forums.raspberrypi.com/viewtopic.php?t=389477 | |
| sudo apt update | |
| sudo apt full-upgrade -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confnew" --purge --auto-remove rpd-wayland-all+ rpd-x-all+ | |
| sudo apt -y clean && sudo apt -y autoremove | |
| # Reboot | |
| sudo reboot | |
| # Modernize sources | |
| sudo apt modernize-sources | |
| # Make sure the following is in /etc/apt/sources.list.d/raspi.sources. The Signed-by: may be missing | |
| Types: deb | |
| URIs: http://archive.raspberrypi.org/debian/ | |
| Suites: trixie | |
| Components: main | |
| Signed-By: /usr/share/keyrings/raspberrypi-archive-keyring.gpg | |
| # Remove the raspi.list.bak after confirming that everything works | |
| sudo rm /etc/apt/sources.list.d/raspi.list.bak |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for the hint.
I checked this on a Raspberry Pi 2 (armhf) after upgrading to Trixie:
More importantly:
apt policy linux-image-rpi-v7lonly shows a locally installed Bookworm version (no candidate)apt-cache/apt listreturn no newer versions at allSo the system ends up with an orphaned Bookworm kernel that cannot be upgraded via apt.
As a workaround, I was only able to get a newer kernel via rpi-update (now running
6.12.73-v7+ #1947 SMP Thu Feb 19 12:27:25 GMT 2026 armv7l GNU/Linuxsince the last run in February), which suggests that newer kernels exist but are not yet published via apt for armhf.This looks like a repository / packaging gap for armhf rather than just a missed migration step.
Today I
sudo apt upgraded two Trixie test systems:6.12.73-v7+ #1947 SMP Thu Feb 19 12:27:25 GMT 2026 armv7l GNU/Linux--> today after upgraded to Pi OS 13.4, kernel still at
6.12.73-v7+ #1947 SMP Thu Feb 19 12:27:25 GMT 2026 armv7l GNU/Linux6.12.62+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.12.62-1+rpt1 (2025-12-18) aarch64 GNU/Linux--> today after upgraded to Pi OS 13.4 kernel got upgraded to
6.12.75+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.12.75-1+rpt1 (2026-03-11) aarch64 GNU/LinuxFurthermore, two more Pi's still running Bookworm:
6.12.75+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.12.75-1+rpt1~bookworm (2026-03-11) aarch64 GNU/Linux6.1.77-v7+ #1768 SMP Tue Jun 4 14:45:11 BST 2024 armv7l GNU/LinuxThat kind of proves my theory: there simply are no kernel updates for 32 bit on armv7l architecture (neither on Bookworm, nor on latest Trixie). Experts, please prove me wrong, but 32 bit seems to be stuck on older kernels, except when running
sudo rpi-update.