Inline upgrade of Debian Buster

Hi all, :wave:

I´m using Debian Buster in a virtual machine (KVM/qemu/virt-manager).

As I´m currently still on Debian 10 (Buster) it´s time to upgrade it to the latest version (Bookworm).
I tried to do so yesterday but my attempt failed, I´m sorry to say. :slightly_frowning_face:

I wanted to upgrade the system directly from Buster to Bookworm. I´m not sure it was the right thing to do.
Should I have perhaps taken the route: Buster —> Bullseye —> Bookworm :question:
Is it in theory possible to skip a version with the inline upgrade :question:

As my first attempt failed I tried another method: upgrade to Bullseye first, but I seem to have run out of virtual disk space.
I need to enlarge it first.

Curiously enough the small disk space wasn´t the issue with my first attempt. Here I ran into difficulties of a different kind.

My steps were the following:

  • take a snapshot of the VM (which proved to be the right thing to do)
  • in Debian: unhold any kept-back packages
  • sudo apt update
  • sudo apt upgrade
  • reboot the system
  • sudo apt dist-upgrade
  • sudo sed -i 's/buster/bullseye/g' /etc/apt/sources.list
  • sudo sed -i 's/buster/bullseye/g' /etc/apt/sources.list.d/*.list
  • sudo apt update
  • sudo apt upgrade
  • sudo apt full-upgrade
  • reboot the system
  • sudo apt autoremove
  • sudo apt clean

The first problem I ran into was:

The step “sudo apt update” after the sources have been changed to bookworm… I got the following message:

Hit:1 http://deb.anydesk.com all InRelease
Hit:2 http://deb.debian.org/debian bookworm InRelease                                       
Ign:3 http://security.debian.org/debian-security bookworm/updates InRelease                 
Hit:4 http://deb.debian.org/debian bookworm-updates InRelease                               
Err:5 http://security.debian.org/debian-security bookworm/updates Release  
  404  Not Found [IP: 146.75.118.132 80]
Hit:6 https://download.docker.com/linux/debian bookworm InRelease          
Reading package lists... Done                        
E: The repository 'http://security.debian.org/debian-security bookworm/updates Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

To address this issue, I temporarily disabled the security updates repository for Bookworm while still proceeding with the upgrade.
Once the correct repository is available, I may re-enable it, I guess.

So I commented out the lines:

# deb http://security.debian.org/debian-security bookworm/updates main
# deb-src http://security.debian.org/debian-security bookworm/updates main

It worked well but I finally ran into the main problem:

After sudo apt full-upgrade (it downloaded all the packages but couldn´t install them): This was the last message I received:

 "/usr/bin/perl: error while loading shared libraries: libcrypt.so.1: cannot open shared object
 file: No such file or directory
dpkg: Fehler beim Bearbeiten des Paketes libc6:amd64 (--configure):
 »installiertes libc6:amd64-Skript des Paketes post-installation«-Unterprozess gab den Fehler
wert 127 zurück
Fehler traten auf beim Bearbeiten von:
 libc6:amd64
Fehler: Zeitüberschreitung wurde erreicht
needrestart is being skipped since dpkg has failed". After that I wanted to restart but the system won´t start anymore.

Sorry, it´s in German.

Basically it´s this:

  • Error processing the package libc6:amd64 (–configure)
  • post-installation sub-process: error 127
  • libc6:amd64: error editing / timeout

I rebooted but couldn´t log in anymore. :frowning_face:

Hmm, as this procedure failed, what would you suggest is the wisest course for doing an inline upgrade from Debian Buster to Bookworm :question:

Many thanks in advance

Cheers from Rosika :slightly_smiling_face:

I dont think that message means what you thought it meant.
I get the same message with my Devuan upgrade attempt.

I think it means more things have to be changed in sources.list than just the release name.
Hang on while I sort it out with Devuan… you can waste a lot of downloads with this sort of thing.

The subsequent errors are all caused by getting the wrong repo.

1 Like

Hi Neville, :wave:

Thanks a lot for the offer. :heart:

I see. I´ll have to investigate further.
This might be the cause why my attempt failed in the end.

Many greetings from Rosika :slightly_smiling_face:

1 Like

If you try again, and it still gives that message, just kill it before it downloads anything. It will be wrong… dont waste the download.

1 Like

Thanks Neville.

That´s good advice indeed.
I´ll have to look for the official Debian guide anyhow. Perhaps there´s another thing I didn´t do right… :thinking: .

Cheers from Rosika :slightly_smiling_face:

@Rosika
Since you are using a VM, I think I would just create a new VM using Debian/Bookworm and just delete the Debian/Buster.

1 Like

Hi Daniel, :wave:

in theory you´re right, of course.

The thing is however: I created that Buster VM quite a while ago and I did it for experimental purposes at the time.
I had no idea I would be using it in a more elaborate way.

In due course I not only installed quite a lot of programmes and experimented with docker, I also applied a lot of changes and introduced some personal data.

Unfortunately I didn´t create a separate home partition and a data partition during the installation process (which I did for my host), so I would lose everything with a fresh install.

I´d like to stick to the inline upgrade, if possible. :neutral_face:

Still: thanks a lot for your suggestion.

Many greetings from Rosika :slightly_smiling_face:

Not quite that bad.
@4dandl4 is right. You can just make another VM, bundle up your home directory into a tarfile, and sftp it across to the new VM. You do lose your installs and configs though.

1 Like

I see, Neville.

Right. This path actually didn´t occur to me. Thanks.

Still: I don´t want to give up on the inline uprade yet. :wink:

Cheers from Rosika :slightly_smiling_face:

1 Like

One should be able to move any data to an ext drive or to a usb stick and transfer data as needed, I do this all the time with the shared folder with VirtualBox.

1 Like

Yes, Daniel, you´re right, of course :blush: .
That should be doable.

Cheers from Rosika :slightly_smiling_face:

1 Like

Yeah, put it anywhere convenient, or just keep the old VM

It might be an idea to keep /etc too.

1 Like

Hi Rosika,
Read man apt-secure(8) and man sources.list(5)
I dont have the answer yet, but it is something to do with
security.
Update: No its not that … see below.

The problem is in the line

deb http://deb.devuan.org/merged deadalus main

If I comment that out , the error messages disappear
but
you cant do without that line…

Solved . See my Devuan upgrade topic.
It was all due to a typo… see the spelling in the above
line from sources.list… it is daedalus NOT deadalus.

Check you spelling in sources.list… you may or may not have the same problem.
Regards
Neville

1 Like

Hi Neville, :wave:

thanks for the update.

Thanks for this hint as well.

Having issues due to a typo can happen to all of us.
The good thing is you found the culprit and you could set it right.

In the meantime I read through Debian´s tutorial for upgrading from Buster to Bullseye:
Chapter 4. Upgrades from Debian 10 (buster) .

Well, I´ll be blessed . It´s some sort of short story rather than a tutorial. :laughing:

I´m pretty intimidated by it and I fear I will miss some crucial point after all…

Has anoyne of you successfully done a Debian inline upgrade yet :question:
If yes: what might the important steps not to miss be?

In my post #1 I provided the steps I followed, but there seems to be more to it, I guess.

Thanks and many greetings from Rosika :slightly_smiling_face:

Hi Rosika,
Yes, I have a Debian hard install in my small desktop, which had an inline upgrade from 10 to 11. I am going to need to do 11 to 12 on it sometime.
There is a complication. It controls grub on my small desktop. If the upgrade fails, it will not boot.
I think I will transfer control of grub to Gentoo, before I start.

I dont have any special tips. Just use the official instructions, and follow them exactly. Be wary of third party instructions.

Regards
Neville

1 Like

Thanks Neville.

O.K., I will have to read it through thouroughly a few times more as it seems quite challenging.

For me it turned out to be a wise decision to have taken a snapshot of the VM beforehand.
So I can start afresh.

I still have to enlarge the qcow2 image first. As it is at the present it´s definitively too small for the upgrade.

Many greetings from Rosika :slightly_smiling_face:

One point.
If you have other repos, eg ppa’s, comment them out in sources.list. They will interfere. You just want the 3 standard deb lines… without typos.

It is a big upgrade… with Devuan my apt-get dist-upgrade had about 1200 gets.

1 Like

Thanks a lot for pointing that out, Neville.

In fact I neglected to take care of PPA´s during my first attempt.

In Buster my sources look like this at present:

rosika2@debian ~> cat /etc/apt/sources.list
# 

# deb cdrom:[Debian GNU/Linux 10.9.0 _Buster_ - Official amd64 xfce-CD Binary-1 20210327-10:42]/ buster main

# deb cdrom:[Debian GNU/Linux 10.9.0 _Buster_ - Official amd64 xfce-CD Binary-1 20210327-10:42]/ buster main

deb http://deb.debian.org/debian/ buster main
deb-src http://deb.debian.org/debian/ buster main

deb http://security.debian.org/debian-security buster/updates main
deb-src http://security.debian.org/debian-security buster/updates main

# buster-updates, previously known as 'volatile'
deb http://deb.debian.org/debian/ buster-updates main
deb-src http://deb.debian.org/debian/ buster-updates main

# This system was installed using small removable media
# (e.g. netinst, live or single CD). The matching "deb cdrom"
# entries were disabled at the end of the installation process.
# For information about how to configure apt package sources,
# see the sources.list(5) manual.
deb [arch=amd64] https://download.docker.com/linux/debian buster stable
# deb-src [arch=amd64] https://download.docker.com/linux/debian buster stable

But there´s also:

rosika2@debian ~> ll /etc/apt/sources.list.d/
insgesamt 8,0K
-rw-r--r-- 1 root root 37 Jun 14  2022 anydesk-stable.list
-rw-r--r-- 1 root root 37 Jun 14  2022 anydesk-stable.list.save
-rw-r--r-- 1 root root  0 Mai  8  2022 xtradeb-ubuntu-apps-kinetic.list
-rw-r--r-- 1 root root  0 Mai  8  2022 xtradeb-ubuntu-apps-kinetic.list.save

So I will have to deal with these as well.

Many greetings from Rosika :slightly_smiling_face:

I dont know what to do with those. Does the official guide say? I would think hide them… move them somewhere else temporarily. You can deal with them separately later.
and
I just remembered, use script . You may need to consult it if it fails. I know, script is an annoying format… but there is no ther way to get a log.

1 Like

Thanks Neville.

I´ll have to take a closer look at it yet.
Moving them somewhere else seems the way to go. That´s certainly a good idea.

Thanks. I´ll do a research on how to implement it for the upgrade process.

Cheers from Rosika :slightly_smiling_face:

1 Like