[Solved] How can I update to Debian 12.2 from Debian 12?

New to Debian (Or Linux in general)? Ask your questions here!
Message
Author
klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

[Solved] How can I update to Debian 12.2 from Debian 12?

#1 Post by klairm »

So I've read that Debian 12.2 comes with security updates and I would like to have my system secure, however If I go to settings and about system it shows Debian 12, not 12.2, and after doing sudo apt update && sudo apt full-upgrade it says everything is updated no new updates shows.

Any ideas? Or maybe is my system already updated? How would I check that?
Last edited by klairm on 2023-10-12 10:53, edited 1 time in total.

User avatar
Hallvor
Global Moderator
Global Moderator
Posts: 2096
Joined: 2009-04-16 18:35
Location: Kristiansand, Norway
Has thanked: 160 times
Been thanked: 226 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#2 Post by Hallvor »

No new updates means that you have the latest version:

Code: Select all

$ cat /etc/debian_version
You only need to run apt update and apt upgrade. Apt full-upgrade is the same as dist-upgrade, and that only makes sense when you have to deal with new dependencies, like upgrading from one Debian release to the next, e.g. from Debian 11 to Debian 12.
[HowTo] Install and configure Debian bookworm
Debian 12 | KDE Plasma | ThinkPad T440s | 4 × Intel® Core™ i7-4600U CPU @ 2.10GHz | 12 GiB RAM | Mesa Intel® HD Graphics 4400 | 1 TB SSD

klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#3 Post by klairm »

cat /etc/debian_version shows 12.1 but not 12.2

User avatar
None1975
df -h | participant
df -h | participant
Posts: 1530
Joined: 2015-11-29 18:23
Location: Russia, Kaliningrad
Has thanked: 63 times
Been thanked: 89 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#4 Post by None1975 »

klairm wrote: 2023-10-10 10:37 cat /etc/debian_version shows 12.1 but not 12.2
Just run:

Code: Select all

sudo apt update
sudo apt upgrade
OS: Debian 12.4 Bookworm / DE: XFCE
Debian Wiki | DontBreakDebian, My config files on github

Fossy
df -h | participant
df -h | participant
Posts: 354
Joined: 2021-08-06 12:45
Has thanked: 35 times
Been thanked: 34 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#5 Post by Fossy »

If You have followed the usual update / upgrade procedure clearly indicated by @Hallvoir and @None 1975 your system would now normally be upgraded to the point version 12.2 without any problems .

And ask me the question whether you have actually used the command " $ cat /etc/debian_version " to find out at what " point _version " , because this is as far as I know ? the only command that indicates this really clearly .

For example , inxi -S , or any other command does not do this ?

Code: Select all

phil@phil-gl753vd:~$ cat /etc/debian_version 
12.2
phil@phil-gl753vd:~$ inxi -S
System:
  Host: phil-gl753vd Kernel: 6.1.0-13-amd64 arch: x86_64 bits: 64
    Desktop: Cinnamon v: 5.6.8 Distro: Debian GNU/Linux 12 (bookworm)
phil@phil-gl753vd:~$ 
Translated with www.DeepL.com/Translator (free version)
ASUS GL753VD / X550LD / K54HR / X751LAB ( x2 )
Bookworm12.8_Cinnamon / Calamares Single Boot installations
Firefox ESR / DuckDuckGo / Thunderbird / LibreOffice / GIMP / eID Software

https://cdimage.debian.org/debian-cd/cu ... so-hybrid/

klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#6 Post by klairm »

still can't get to 12.2, when I run update and upgrade it doesn't gets anything new ( as I said in first post )

Code: Select all

ivan@debian:~$ sudo apt update
[sudo] contraseña para ivan: 
Obj:1 http://deb.debian.org/debian bookworm InRelease
Obj:2 http://deb.debian.org/debian bookworm-updates InRelease
Obj:3 http://security.debian.org/debian-security bookworm-security InRelease
Leyendo lista de paquetes... Hecho
Creando árbol de dependencias... Hecho
Leyendo la información de estado... Hecho
Todos los paquetes están actualizados.
ivan@debian:~$ sudo apt upgrade
Leyendo lista de paquetes... Hecho
Creando árbol de dependencias... Hecho
Leyendo la información de estado... Hecho
Calculando la actualización... Hecho
0 actualizados, 0 nuevos se instalarán, 0 para eliminar y 0 no actualizados.
ivan@debian:~$ inxi -S
System:
  Host: debian Kernel: 6.1.0-12-amd64 arch: x86_64 bits: 64 Desktop: GNOME
    v: 43.6 Distro: Debian GNU/Linux 12 (bookworm)
ivan@debian:~$ cat /etc/debian_version 
12.1

dlu2021
Posts: 231
Joined: 2021-08-13 19:55
Location: Minnesota
Has thanked: 8 times
Been thanked: 43 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#7 Post by dlu2021 »

Can you share the contents of the /etc/apt/sources.list file?

Fossy
df -h | participant
df -h | participant
Posts: 354
Joined: 2021-08-06 12:45
Has thanked: 35 times
Been thanked: 34 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#8 Post by Fossy »

@klairm
No sé de dónde has sacado el tuyo, pero yo trabajo con las siguientes fuentes:
$ sudo nano /etc/apt/sources.list :

Code: Select all

deb https://deb.debian.org/debian/ bookworm main contrib non-free non-free-firmware
deb https://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware
deb https://security.debian.org/debian-security/ bookworm-security main contrib non-free non-free-firmware
prueba a experimentar una vez ?
éxito
ASUS GL753VD / X550LD / K54HR / X751LAB ( x2 )
Bookworm12.8_Cinnamon / Calamares Single Boot installations
Firefox ESR / DuckDuckGo / Thunderbird / LibreOffice / GIMP / eID Software

https://cdimage.debian.org/debian-cd/cu ... so-hybrid/

User avatar
pbear
Posts: 509
Joined: 2023-08-27 15:05
Location: San Francisco
Has thanked: 2 times
Been thanked: 81 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#9 Post by pbear »

Approximately how long ago did you install the system? Has it ever updated/upgraded successfully?

klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#10 Post by klairm »

I installed Debian about less than a month ago, it has updated some packages sometimes

Fossy
df -h | participant
df -h | participant
Posts: 354
Joined: 2021-08-06 12:45
Has thanked: 35 times
Been thanked: 34 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#11 Post by Fossy »

klairm wrote: 2023-10-10 10:37 cat /etc/debian_version shows 12.1 but not 12.2
On second thought and with all due respect , your story , to evidence to the contrary is not correct .
In my opinion , it cannot be that , if done correctly , performing the last upgrade put your system to 12.1 instead of 12.2 .
Drop mic
ASUS GL753VD / X550LD / K54HR / X751LAB ( x2 )
Bookworm12.8_Cinnamon / Calamares Single Boot installations
Firefox ESR / DuckDuckGo / Thunderbird / LibreOffice / GIMP / eID Software

https://cdimage.debian.org/debian-cd/cu ... so-hybrid/

User avatar
pbear
Posts: 509
Joined: 2023-08-27 15:05
Location: San Francisco
Has thanked: 2 times
Been thanked: 81 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#12 Post by pbear »

Fossy wrote: 2023-10-11 12:38 ... it cannot be that , if done correctly , performing the last upgrade put your system to 12.1 instead of 12.2 .
This is obviously correct. The nub of the problem is that the last upgrade did not go through.

User avatar
pbear
Posts: 509
Joined: 2023-08-27 15:05
Location: San Francisco
Has thanked: 2 times
Been thanked: 81 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#13 Post by pbear »

klairm wrote: 2023-10-11 08:37 I installed Debian about less than a month ago, it has updated some packages sometimes
In English, we call this a "locked room mystery." Seemingly impossible, yet it has happened somehow.
FWIW, I can't think of a case where dpkg refused to work without giving some explanation why.

Please post the output of cat /etc/apt/sources.list (as requested by dlu2021).
Please post also the output of ls /boot.

klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#14 Post by klairm »

this is my apt sources

Code: Select all

#deb cdrom:[Debian GNU/Linux 12.1.0 _Bookworm_ - Official amd64 NETINST with firmware 20230722-10:48]/ bookworm main non-free-firmware

#deb http://deb.debian.org/debian/ bookworm main non-free-firmware
deb-src http://deb.debian.org/debian/ bookworm main non-free-firmware
deb http://deb.debian.org/debian/ bookworm main contrib non-free non-free-firmware
deb http://security.debian.org/debian-security bookworm-security main non-free-firmware
deb-src http://security.debian.org/debian-security bookworm-security main non-free-firmware
# bookworm-updates, to get updates before a point release is made;
# see https://www.debian.org/doc/manuals/debian-reference/ch02.en.html#_updates_and_backports
deb http://deb.debian.org/debian/ bookworm-updates main non-free-firmware
deb-src http://deb.debian.org/debian/ bookworm-updates main non-free-firmware

# 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.
and listing /boot :

Code: Select all

config-6.1.0-10-amd64  initrd.img-6.1.0-10-amd64  vmlinuz-6.1.0-10-amd64
config-6.1.0-12-amd64  initrd.img-6.1.0-12-amd64  vmlinuz-6.1.0-12-amd64
efi                    System.map-6.1.0-10-amd64
grub                   System.map-6.1.0-12-amd64

Fossy
df -h | participant
df -h | participant
Posts: 354
Joined: 2021-08-06 12:45
Has thanked: 35 times
Been thanked: 34 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#15 Post by Fossy »

1/ Since you have Bookworm 12.1 installed and not Bookworm 12 as you misleadingly indicate, it makes sense that given your update problem cat /etc/debian_version displays version 12.1 .

2/ As for updating I would like to refer to @Hallvor 's topic ... strongly recommend that you go through it thoroughly:

viewtopic.php?p=781767&hilit=netinstall+update#p781767

4.1 Getting a functional system
Debian's main source of software is determined by sources.list. It is a configuration file determining what and from where software can be fetched. Non-free firmware should be included for your hardware when needed, so not all steps below may be necessary.

4.1.1 Sources.list
You can edit sources.list by issuing the following command:
Code: Select all
# nano /etc/apt/sources.list

Then remove or comment out the CD-rom line with a #, if it is present:
Code: Select all
#deb cdrom://[Debian GNU/Linux 12.0.0 _Bookworm_ - Official amd64 DVD Binary-1 with firmware 20230610-10:23] bookworm Release

My sources.list looks like this: I added contrib and non-free because some packages are not found in main or non-free-firmware.
Code: Select all
deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware

#deb-src http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware

deb http://deb.debian.org/debian-security/ bookworm-security main contrib non-free non-free-firmware
#deb-src http://deb.debian.org/debian-security/ bookworm-security main contrib non-free non-free-firmware

deb http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware
#deb-src http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware


The deb-src can be commented out unless you want to build something from source. This will save data traffic.

Save and exit with Ctrl-x, and then y to confirm.

Update your sources.list and apply updates
Code: Select all
# apt update && apt upgrade
ASUS GL753VD / X550LD / K54HR / X751LAB ( x2 )
Bookworm12.8_Cinnamon / Calamares Single Boot installations
Firefox ESR / DuckDuckGo / Thunderbird / LibreOffice / GIMP / eID Software

https://cdimage.debian.org/debian-cd/cu ... so-hybrid/

User avatar
pbear
Posts: 509
Joined: 2023-08-27 15:05
Location: San Francisco
Has thanked: 2 times
Been thanked: 81 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#16 Post by pbear »

Fossy wrote: 2023-10-11 22:26 ... misleadingly indicate
That's the second time you've accused the OP of lying, and you're wrong again. He (or she) didn't know how to check the system's status. Said so in the first post. Second post explained how. The OP ran the check and posted the information in the third post. All of this, of course, before your first post in the thread.
klairm wrote: 2023-10-11 16:50 this is my apt sources
You might have mentioned you had edited the file. The installer commented out the cdrom line, but you commented out the next one, presumably in favor of the new third line. On the other hand, that change shouldn't cause this problem and, indeed, I just tested upgrading a VM (still on 12.1) using your sources.list file and it worked fine (VM now at 12.2 and has the -13 kernel).

Nothing wrong with trying the edit Fossy suggests. Copy the file before editing (sudo cp /etc/apt/sources.list /etc/apt/sources.backup). I doubt it will make any difference though.

If no one else comes up with a bright idea, you're probably looking at reinstall. Did you do anything else related to packages besides editing /etc/apt/sources.list? Whatever it was (and there almost has to be something), you might want to pass on that next time, or do some research on how to do whatever you were trying to accomplish in a different way.

dlu2021
Posts: 231
Joined: 2021-08-13 19:55
Location: Minnesota
Has thanked: 8 times
Been thanked: 43 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#17 Post by dlu2021 »

I think that the issue sounds similar to this recent thread.

The TLDR is that the file times got out of whack somehow, which stopped the updates from happening and used these commands to fix them:

Code: Select all

#mv /var/lib/apt/lists/ /var/lib/apt/lists-SAVE/
#apt update

klairm
Posts: 29
Joined: 2023-09-14 12:13
Has thanked: 1 time

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#18 Post by klairm »

dlu2021 wrote: 2023-10-12 03:58 I think that the issue sounds similar to this recent thread.

The TLDR is that the file times got out of whack somehow, which stopped the updates from happening and used these commands to fix them:

Code: Select all

#mv /var/lib/apt/lists/ /var/lib/apt/lists-SAVE/
#apt update
Thanks this worked, now is time to fight about the kernel module sign since I have secure boot enabled and nvidia drivers requires to sign the module to load, but I already done this before so guess is not hard.

thanks a lot!

dlu2021
Posts: 231
Joined: 2021-08-13 19:55
Location: Minnesota
Has thanked: 8 times
Been thanked: 43 times

Re: [Solved] How can I update to Debian 12.2 from Debian 12?

#19 Post by dlu2021 »

No problem, glad to help.

Also thanks to @fabien for doing the deep dive on the original thread to figure out the issue.

mike-w0btu
Posts: 1
Joined: 2023-10-20 19:25
Has thanked: 5 times

Re: [Software] How can I update to Debian 12.2 from Debian 12?

#20 Post by mike-w0btu »

dlu2021 wrote: 2023-10-12 03:58 ...

Code: Select all

#mv /var/lib/apt/lists/ /var/lib/apt/lists-SAVE/
#apt update
I just tried this, and it did not work for me. I'm still on 12[.0] after running those apt commands. Anything else to try? :-)

EDIT:
Solved! Edited /etc/sources.list and changed http to https.

cat /etc/debian_version now shows 12.2. :)

Post Reply