This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Can't install updates.

Tags: None
(comma "," separated)
jwt873
Registered Member
Posts
35
Karma
0

Can't install updates.

Thu Mar 11, 2021 1:37 pm
The last time I installed Neon updates, (a few days ago), the process ended suddenly and I was logged out. (Taken to the login screen). I logged back in and things seemed to be OK.

I had some updates today and when I tried to run them, Discover returned the error:

Cannot obtain lock E:dpkg was interrupted, you must manually run dpkg --configure -a to correct the problem

If I run the command dpkg --configure -a, the term 'setting up sddm' appears in the terminal window and the system logs me off.

I ran the updates using pkcon. Below is the output I see:

Code: Select all
jim@linux:~$ sudo pkcon update
Getting updates        [=========================]         
Finished                      [=========================]         
Loading cache           [=========================]         
Testing changes        [=========================]         
Finished                      [                                                       ] (0%)
  The following packages have to be updated:
 linux-firmware-1.187.10.all    Firmware for Linux kernel drivers
 xsane-0.999-8ubuntu2.1.amd64   featureful graphical frontend for SANE (Scanner Access Now Easy)
 xsane-common-0.999-8ubuntu2.1.all      xsane architecture independent files
Proceed with changes? [N/y] y

                                               [=========================]         
Updating packages             [=========================]         
Waiting for package manager lock[=========================]         
Finished                                [=========================]         
Fatal error: E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem.

Every time I run sudo dpkg --configure -a, the term 'setting up sddm' appears in the terminal window and the system instantly logs me off. Not sure where else to look..

Edit.. Also tried 'pkcon repair' It does the same thing.. I get logged out and when I log back in, the problem persists.
dfoskett
Registered Member
Posts
34
Karma
0
OS

Re: Can't install updates.

Thu Mar 11, 2021 3:27 pm
Similar problem twice over, once on a laptop, once on a desktop. In the case of the laptop I was actually updating from 18.04 to 20.04 (with a GUI) and with 4% left it logged me out and now won't boot (i can boot into an older kernel, though the windowing systems seems to not be working right so it's not useable). dpkg --configure -a just quickly logs me out. Ran the update on my desktop via discovery, and it also logged me out partway though. I'm sure if I reboot it, it won't work, so I'm leaving it running for now.

Any suggestions would be greatly appreciated.
jwt873
Registered Member
Posts
35
Karma
0

Re: Can't install updates.

Thu Mar 11, 2021 3:55 pm
I seem to have found a fix..

Prior to my post in this forum I had Googled for an answer and Google supplied a few dozen hits. All the proposed solutions I read in these hits didn't work.

After posting my question I went through a few dozen more Google results.. I finally found one that works! Here's what I did to fix the update issue:

sudo rm /var/lib/apt/lists/lock
sudo rm /var/cache/apt/archives/lock
cd /var/lib/dpkg/updates
sudo rm *
sudo apt-get update

(NOTE.. sudo rm * is dangerous.. Make sure you're actually in the directory /var/lib/dpkg/updates when you run it).
dfoskett
Registered Member
Posts
34
Karma
0
OS

Re: Can't install updates.

Thu Mar 11, 2021 5:13 pm
Thanks, that fixed it!


Bookmarks



Who is online

Registered users: bartoloni, Bing [Bot], Google [Bot], Yahoo [Bot]