Error while updating linux image Topic is solved

Having issues with your DietPi installation or found a bug? Post it here.
CbIP
Posts: 24
Joined: Mon Jan 25, 2021 11:25 am

Error while updating linux image

Post by CbIP »

Hi all!

During the package update routine (apt update && apt upgrade) I faced with an error:

Code: Select all

The following packages have unmet dependencies:
 linux-image-cloud-arm64 : Depends: linux-image-5.10.0-0.bpo.8-cloud-arm64 (= 5.10.46-4~bpo10+1) but 5.10.46-2~bpo10+1 is installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
If I run the suggested command I get the following error:

Code: Select all

Unpacking linux-image-5.10.0-0.bpo.8-cloud-arm64 (5.10.46-4~bpo10+1) over (5.10.46-2~bpo10+1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-5.10.0-0.bpo.8-cloud-arm64_5.10.46-4~bpo10+1_arm64.deb (--unpack):
 unable to make backup link of './boot/System.map-5.10.0-0.bpo.8-cloud-arm64' before installing new version: Operation not permitted
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/linux-image-5.10.0-0.bpo.8-cloud-arm64_5.10.46-4~bpo10+1_arm64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Here is the list of installed linux images:

Code: Select all

ii  linux-image-5.10.0-0.bpo.7-cloud-arm64 5.10.40-1~bpo10+1              arm64        Linux 5.10 for arm64 cloud (signed)
ii  linux-image-5.10.0-0.bpo.8-cloud-arm64 5.10.46-2~bpo10+1              arm64        Linux 5.10 for arm64 cloud (signed)
rc  linux-image-5.9.0-0.bpo.5-cloud-arm64  5.9.15-1~bpo10+1               arm64        Linux 5.9 for arm64 cloud (signed)
iU  linux-image-cloud-arm64                5.10.46-4~bpo10+1              arm64        Linux for arm64 cloud (meta-package)
I also tried to run apt install --reinstall linux-image-cloud-arm64, but got the same error

Does anybody know how to fix the issue with linux image update?
User avatar
Joulinar
Posts: 5619
Joined: Sat Nov 16, 2019 12:49 am

Re: Error while updating linux image

Post by Joulinar »

can you try to reboot your system and run apt autoremove afterwards.

once done apt install --reinstall linux-image-5.10.0-0.bpo.8-cloud-arm64
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
CbIP
Posts: 24
Joined: Mon Jan 25, 2021 11:25 am

Re: Error while updating linux image

Post by CbIP »

apt autoremove after reboot shows the same error:

Code: Select all

You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 linux-image-cloud-arm64 : Depends: linux-image-5.10.0-0.bpo.8-cloud-arm64 (= 5.10.46-4~bpo10+1) but 5.10.46-2~bpo10+1 is installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
as well as apt install --reinstall linux-image-5.10.0-0.bpo.8-cloud-arm64:

Code: Select all

Preparing to unpack .../linux-image-5.10.0-0.bpo.8-cloud-arm64_5.10.46-4~bpo10+1_arm64.deb ...
Unpacking linux-image-5.10.0-0.bpo.8-cloud-arm64 (5.10.46-4~bpo10+1) over (5.10.46-2~bpo10+1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-5.10.0-0.bpo.8-cloud-arm64_5.10.46-4~bpo10+1_arm64.deb (--unpack):
 unable to make backup link of './boot/System.map-5.10.0-0.bpo.8-cloud-arm64' before installing new version: Operation not permitted
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/linux-image-5.10.0-0.bpo.8-cloud-arm64_5.10.46-4~bpo10+1_arm64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
I have found some information here: https://bugs.launchpad.net/ubuntu/+sour ... ug/1318951
They recommend to boot into another installed image, purge the defective one and reinstall it. But I do not know how to boot Pi into another image. Also, adding lines

Code: Select all

do_symlinks = No
no_symlinks = Yes
to /etc/kernel-img.conf did nothing (but I didn't reboot the Pi afterwards)
User avatar
Joulinar
Posts: 5619
Joined: Sat Nov 16, 2019 12:49 am

Re: Error while updating linux image

Post by Joulinar »

could you let me know what SBC you are running? is it a Raspberry Pi?
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
CbIP
Posts: 24
Joined: Mon Jan 25, 2021 11:25 am

Re: Error while updating linux image

Post by CbIP »

Yes, it is Raspberry Pi 4 Model B with 8Gb RAM
Currently running DietPi 7.4.2 - cannot update it because of the issue.
User avatar
Joulinar
Posts: 5619
Joined: Sat Nov 16, 2019 12:49 am

Re: Error while updating linux image

Post by Joulinar »

hmm I'm wonder why you have linux-image-cloud-arm64 package installed at all. Usually it is used on cloud platforms supporting arm64 virtual machines. As well it is installed from Buster backports indicated by bpo10 within the package name. Was there any reason to have it installed? :?

Usually an Raspberry Pi, kernel from Raspbian repository is used and not a kernel for cloud platform.

Let me ping our developer @MichaIng
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
CbIP
Posts: 24
Joined: Mon Jan 25, 2021 11:25 am

Re: Error while updating linux image

Post by CbIP »

No, I didn't change the image package by myself. Or at least at my own will: it might be installed by some other package...
User avatar
Joulinar
Posts: 5619
Joined: Sat Nov 16, 2019 12:49 am

Re: Error while updating linux image

Post by Joulinar »

can you check if the Raspbian kernel package is installed

Code: Select all

dpkg -l *kernel*
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
CbIP
Posts: 24
Joined: Mon Jan 25, 2021 11:25 am

Re: Error while updating linux image

Post by CbIP »

It shows the following output:

Code: Select all

| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                   Version        Architecture Description
+++-======================-==============-============-=================================
un  debian-kernel-handbook <none>         <none>       (no description available)
un  kernel-common          <none>         <none>       (no description available)
ii  raspberrypi-kernel     1:1.20210805-1 arm64        Raspberry Pi bootloader

UPD. I didn't find any v.5 images except for cloud and backports available:

Code: Select all

apt list linux-image*
Listing... Done
linux-image-4.19.0-12-arm64/oldstable 4.19.152-1 arm64
linux-image-4.19.0-12-rt-arm64/oldstable 4.19.152-1 arm64
linux-image-4.19.0-14-arm64-dbg/oldstable 4.19.171-2 arm64
linux-image-4.19.0-14-arm64-unsigned/oldstable 4.19.171-2 arm64
linux-image-4.19.0-14-arm64/oldstable 4.19.171-2 arm64
linux-image-4.19.0-14-rt-arm64-dbg/oldstable 4.19.171-2 arm64
linux-image-4.19.0-14-rt-arm64-unsigned/oldstable 4.19.171-2 arm64
linux-image-4.19.0-14-rt-arm64/oldstable 4.19.171-2 arm64
linux-image-4.19.0-16-arm64-dbg/oldstable 4.19.181-1 arm64
linux-image-4.19.0-16-arm64-unsigned/oldstable 4.19.181-1 arm64
linux-image-4.19.0-16-arm64/oldstable 4.19.181-1 arm64
linux-image-4.19.0-16-rt-arm64-dbg/oldstable 4.19.181-1 arm64
linux-image-4.19.0-16-rt-arm64-unsigned/oldstable 4.19.181-1 arm64
linux-image-4.19.0-16-rt-arm64/oldstable 4.19.181-1 arm64
linux-image-4.19.0-17-arm64-dbg/oldstable 4.19.194-3 arm64
linux-image-4.19.0-17-arm64-unsigned/oldstable 4.19.194-3 arm64
linux-image-4.19.0-17-arm64/oldstable 4.19.194-3 arm64
linux-image-4.19.0-17-rt-arm64-dbg/oldstable 4.19.194-3 arm64
linux-image-4.19.0-17-rt-arm64-unsigned/oldstable 4.19.194-3 arm64
linux-image-4.19.0-17-rt-arm64/oldstable 4.19.194-3 arm64
linux-image-4.19.0-6-arm64/oldstable 4.19.67-2+deb10u2 arm64
linux-image-4.19.0-6-rt-arm64/oldstable 4.19.67-2+deb10u2 arm64
linux-image-4.19.0-8-arm64/oldstable 4.19.98-1+deb10u1 arm64
linux-image-4.19.0-8-rt-arm64/oldstable 4.19.98-1+deb10u1 arm64
linux-image-4.19.0-9-arm64/oldstable 4.19.118-2+deb10u1 arm64
linux-image-4.19.0-9-rt-arm64/oldstable 4.19.118-2+deb10u1 arm64
linux-image-5.10.0-0.bpo.7-arm64/buster-backports 5.10.40-1~bpo10+1 arm64
linux-image-5.10.0-0.bpo.7-cloud-arm64/buster-backports,now 5.10.40-1~bpo10+1 arm64 [installed,automatic]
linux-image-5.10.0-0.bpo.7-rt-arm64/buster-backports 5.10.40-1~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-arm64-dbg/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-arm64-unsigned/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-arm64/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-cloud-arm64-dbg/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-cloud-arm64-unsigned/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-cloud-arm64/buster-backports 5.10.46-4~bpo10+1 arm64 [upgradable from: 5.10.46-2~bpo10+1]
linux-image-5.10.0-0.bpo.8-rt-arm64-dbg/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-rt-arm64-unsigned/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.10.0-0.bpo.8-rt-arm64/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-5.9.0-0.bpo.5-cloud-arm64/now 5.9.15-1~bpo10+1 arm64 [residual-config]
linux-image-arm64-dbg/oldstable 4.19+105+deb10u12 arm64
linux-image-arm64-signed-template/oldstable 4.19.194-3 arm64
linux-image-arm64/oldstable 4.19+105+deb10u12 arm64
linux-image-cloud-arm64-dbg/buster-backports 5.10.46-4~bpo10+1 arm64
linux-image-cloud-arm64/buster-backports,now 5.10.46-4~bpo10+1 arm64 [installed,automatic]
linux-image-rt-arm64-dbg/oldstable 4.19+105+deb10u12 arm64
linux-image-rt-arm64/oldstable 4.19+105+deb10u12 arm64
User avatar
Joulinar
Posts: 5619
Joined: Sat Nov 16, 2019 12:49 am

Re: Error while updating linux image

Post by Joulinar »

usually there is no need to install any linux-image package on RPi. This should not be needed.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply