{"id":830,"date":"2026-06-27T07:06:02","date_gmt":"2026-06-27T07:06:02","guid":{"rendered":"https:\/\/www.micha.name\/blog\/?p=830"},"modified":"2026-06-27T07:19:19","modified_gmt":"2026-06-27T07:19:19","slug":"server-upgrade-debian-12-bookworm-to-debian-13-trixie","status":"publish","type":"post","link":"https:\/\/www.micha.name\/blog\/2026\/06\/27\/server-upgrade-debian-12-bookworm-to-debian-13-trixie\/","title":{"rendered":"Server Upgrade: Debian 12 &#8220;bookworm&#8221; to Debian 13 &#8220;trixie&#8221;"},"content":{"rendered":"<h2>Overview<\/h2>\n<p>Yes, I know &#8220;trixie&#8221; has been out and stable for over half a year now. In fact, it&#8217;s been running on my desktop shortly after it was released. But servers are another kettle of fish, and in the past it&#8217;s taken some time to ensure everything is upgraded and working correctly. So I finally set aside a weekend for the update..<\/p>\n<p>TL;DR: apart from breaking <code>mariadb<\/code>, everything went pretty smoothly..<\/p>\n<h2>What worked well<\/h2>\n<p>The standard update steps worked well:<\/p>\n<ul>\n<li>apt update &amp;&amp; apt upgrade<\/li>\n<li>edit all of the `sources.list` to change <code>bookworm<\/code> to <code>trixie<\/code>.<\/li>\n<li>apt update &amp;&amp; apt full-upgrade<\/li>\n<li>update various configuration files &#8211; <code>vimdiff<\/code> works very well for this!<\/li>\n<\/ul>\n<p>There were no errors or issues, and the system rebooted cleanly with its new kernel.<\/p>\n<h2>What broke<\/h2>\n<p>Part-way through the upgrade, the system ran out of space in <code>\/var<\/code>. While I&#8217;m not entirely sure, I suspect that this is what caused <code>mariadb<\/code> to be broken following the restart. I noticed since neither <code>roundcube<\/code> nor <code>nextcloud<\/code> started up following the reboot.<\/p>\n<p>That&#8217;s when I noticed that the database wasn&#8217;t running..<\/p>\n<p>Eventually I managed to rescue the database by using the <code>innodb_force_recovery<\/code> option. Of course I immediately did a full database dump and then reinitialized the entire database using the dump.<\/p>\n<p>Despite the database being back up and running, <code>nextcloud<\/code> still refused to run. This was due to php8.2 having been upgraded, but the <code>php8.2-redis<\/code> package is not available in Debian 13. I spent quite a bit of time trying various things, including changing to php8.4 which my version of Nextcloud did not yet support. I eventually &#8220;fixed&#8221; it by simply disabling the redis configuration in Nextcloud..<\/p>\n<p>The only other thing to break was <code>exim4<\/code> because I accidentally duplicated a configuration key while merging the configuration from the upstream maintainer, but this was quickly fixed.<\/p>\n<h2>What I learned (again)<\/h2>\n<ul>\n<li><strong>ALWAYS<\/strong> take backups, no matter how sure you are that things will go smoothly.<\/li>\n<li>Ensure you have enough disk-space. I had checked and thought I had enough, but part-way through the upgrade ran out..<\/li>\n<li>Ensure all critical apps are upgraded or can run with the new versions of any dependencies after the system has been upgraded.<\/li>\n<\/ul>\n<h2>Follow-up Steps<\/h2>\n<ul>\n<li>Upgraded Nextcloud from 30 to 34, mostly using the web updater, although a few versions required some additional manual twiddling. I wish Nextcloud would have Long Term Service (LTS) releases..<\/li>\n<li>Switched the system to php8.4 and removed php8.2<\/li>\n<li>Upgraded Piwigo from 14.5 to 16.4<\/li>\n<\/ul>\n<p>There may be more things which I need to tweak\/fix over the coming weeks, but the essentials are working &#8211; web, email, cloud, and photo albums.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview Yes, I know &#8220;trixie&#8221; has been out and stable for over half a year now. In fact, it&#8217;s been running on my desktop shortly after it was released. But servers are another kettle of fish, and in the past it&#8217;s taken some time to ensure everything is upgraded and working correctly. So I finally set aside a weekend for the update.. TL;DR: apart from breaking mariadb, everything went pretty smoothly.. What worked well The standard update steps worked well: apt update &amp;&amp; apt upgrade edit all of the `sources.list` to change bookworm to trixie. apt update &amp;&amp; apt full-upgrade update various configuration files &#8211; vimdiff works very well for this! There were no errors or issues, and the system rebooted cleanly with its new kernel. What broke Part-way through the upgrade, the system ran out of space in \/var. While I&#8217;m not entirely sure, I suspect that this is what caused mariadb to be broken following the restart. I noticed since neither roundcube nor nextcloud started up following the reboot. That&#8217;s when I noticed that the database wasn&#8217;t running.. Eventually I managed to rescue the database by using the innodb_force_recovery option. Of course I immediately did a full database [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11,56,29],"tags":[30],"class_list":["post-830","post","type-post","status-publish","format-standard","hentry","category-computers","category-linux","category-technology","tag-linux"],"_links":{"self":[{"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/posts\/830","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/comments?post=830"}],"version-history":[{"count":3,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/posts\/830\/revisions"}],"predecessor-version":[{"id":833,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/posts\/830\/revisions\/833"}],"wp:attachment":[{"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/media?parent=830"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/categories?post=830"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.micha.name\/blog\/wp-json\/wp\/v2\/tags?post=830"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}