[SOLVED] Package 'stuck' in Package Manager.

Questions about applications and software
Forum rules
Before you post please read how to get help
Post Reply
bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

[SOLVED] Package 'stuck' in Package Manager.

Post by bobltx » Fri Oct 18, 2019 8:53 am

Linux Mint 18.2 Sonya 64bit.

I have a package, hl1450lpr:i386, which is marked red in Package Manager for removal and it is preventing me from doing any updates. If I try to Unmark it immediately it goes back to red again. The Brother HL1450 printer on this machine is working as is the HP Deskjet 5550 so I don't really want to uninstall
anything. I have tried to remove it thus:

Code: Select all

bob@MainDesk ~ $ sudo apt-get remove hl1450lpr:i386
[sudo] password for bob: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED
  hl1450lpr:i386
0 to upgrade, 0 to newly install, 1 to remove and 83 not to upgrade.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] 
(Reading database ... 812444 files and directories currently installed.)
Removing hl1450lpr:i386 (1.1.2-1) ...
/var/lib/dpkg/info/hl1450lpr.postrm: 3: /var/lib/dpkg/info/hl1450lpr.postrm: /etc/init.d/lpd: not found
dpkg: error processing package hl1450lpr:i386 (--remove):
 subprocess installed post-removal script returned error exit status 127
Errors were encountered while processing:
 hl1450lpr:i386
E: Sub-process /usr/bin/dpkg returned an error code (1)
Whenever I try to install anything with package manager I get the same error message " subprocess installed post-removal script returned error
exit status 127" and nothing is done.

I have tried to find "hl1450lpr:i386" using Midnight Commander but have come up with nothing. Is it trying to remove a package that doesn't exist?
Anyone got any ideas short of a complete re-install of the operating system? :cry:
Last edited by Moem on Wed Nov 06, 2019 9:08 am, edited 2 times in total.
Reason: Marked this as [SOLVED] for you; please note that you can and should do this for your own topics. Thanks!
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

DAMIEN1307
Level 8
Level 8
Posts: 2227
Joined: Tue Feb 21, 2017 8:13 pm
Location: Alamogordo, New Mexico, USA

Re: Package 'stuck' in Package Manager.

Post by DAMIEN1307 » Fri Oct 18, 2019 9:03 am

Try this first and see if it fixes things for you...DAMIEN

Code: Select all

sudo apt-get --fix-broken install 
Follow up with:

Code: Select all

sudo apt update
Then refresh your update manager and see if things are back to normal.
ORDO AB CHAO

User avatar
Flemur
Level 17
Level 17
Posts: 7334
Joined: Mon Aug 20, 2012 9:41 pm
Location: Potemkin Village

Re: Package 'stuck' in Package Manager.

Post by Flemur » Fri Oct 18, 2019 9:22 am

If DAMIEN1307's advice doesn't work, try installing the package again, then uninstalling it.
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?

bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

Re: Package 'stuck' in Package Manager.

Post by bobltx » Sun Oct 27, 2019 6:55 pm

Thanks Guys,

Tried that Damien but it didn't help, the problem is still there.
Then tried a re-install but just keep getting the same error message.
No matter what I try it is unchangeable, I have tried to find it with MC but it seemingly doesn't exist.
If I unplug the printer and then remove it from "Configure Printers" in the main menu do you think
that will solve the problem? Then plug it back in as a 'new' printer which will hopefully be recognized.

Sorry for the long delay in following this up but medical issues keep getting in the way :-)
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

User avatar
ricardogroetaers
Level 4
Level 4
Posts: 233
Joined: Sat Oct 27, 2018 3:06 am
Location: Rio de Janeiro, Brasil

Re: Package 'stuck' in Package Manager.

Post by ricardogroetaers » Wed Oct 30, 2019 10:53 pm

go in:
Application Sources -> Maintenance
Click on:
- Fix update list issues (MergeList)
-Clean residual setting

Refresh the cache.

Image

bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

Re: Package 'stuck' in Package Manager.

Post by bobltx » Thu Oct 31, 2019 4:30 am

Thanks ricardogroetaers,
Tried your suggestion but when I update the cache I get this:

W: http://www.openprinting.org/download/pr ... elease.gpg: Signature by key F8897B6F00075648E248B7EC24CBF5474CFD1E2F uses weak digest algorithm (SHA1)

Followed by:
E: hl1450lpr: 0.0000:subprocess installed post-removal script returned error exit status 127

Then tried to do a software update but it failed with the same error message as before.

Looks like I'll have to back up all the data, not an easy job , then format the SSD and start again :(

Thanks for your input.
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

User avatar
ricardogroetaers
Level 4
Level 4
Posts: 233
Joined: Sat Oct 27, 2018 3:06 am
Location: Rio de Janeiro, Brasil

Re: Package 'stuck' in Package Manager.

Post by ricardogroetaers » Sat Nov 02, 2019 1:20 am

bobltx wrote:
Thu Oct 31, 2019 4:30 am
Looks like I'll have to back up all the data, not an easy job , then format the SSD and start again :(
Before taking this radical step, try:

Go to "Application Sources":
- Authentication Keys -> Remove All
- Additional repositories -> remove everything except "CD-ROM" (which should remain but unchecked).
- PPAs -> remove everything.

Go back to "Maintenance" and repeat the steps from the previous post.

bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

Re: Package 'stuck' in Package Manager.

Post by bobltx » Sat Nov 02, 2019 4:14 am

Thanks again ricardogroetaers ,

Done as you suggested but the problem is still there when I try to update the cache I get 'An error occurred' window;

E: hl1450lpr: 0.0000:subprocess installed post-removal script returned error exit status 127

And the 'Changes applied' window shows;

Code: Select all

(Reading database ... 812444 files and directories currently installed.)
Removing hl1450lpr:i386 (1.1.2-1) ...
/var/lib/dpkg/info/hl1450lpr.postrm: 3: /var/lib/dpkg/info/hl1450lpr.postrm: /etc/init.d/lpd: not found
dpkg: error processing package hl1450lpr:i386 (--remove):
 subprocess installed post-removal script returned error exit status 127
Errors were encountered while processing:
 hl1450lpr:i386
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

User avatar
ricardogroetaers
Level 4
Level 4
Posts: 233
Joined: Sat Oct 27, 2018 3:06 am
Location: Rio de Janeiro, Brasil

Re: Package 'stuck' in Package Manager.

Post by ricardogroetaers » Sat Nov 02, 2019 10:49 pm

Open synaptic.
-> settings -> preferences -> go to files tab
Click the "delete cache package files" button
Click the apply button
click the ok button
close synaptic
open synaptic
wait for "search index update" to finish.

bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

Re: Package 'stuck' in Package Manager.

Post by bobltx » Wed Nov 06, 2019 3:49 am

Thanks Ricardo, tried that, clicked on the apply button but when I try to close synaptic I get the message:

"Quit and discard marked changes"

It seems that nothing has happened because this error message is shown again when I click on the apply icon
at the top of synaptic;

E: hl1450lpr: 0.0000:subprocess installed post-removal script returned error exit status 127

This error is blocking everything else from happening.
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

gm10
Level 19
Level 19
Posts: 9820
Joined: Thu Jun 21, 2018 5:11 pm

Re: Package 'stuck' in Package Manager.

Post by gm10 » Wed Nov 06, 2019 4:11 am

You can fix your immediate problem with this:

Code: Select all

sudo rm -v /var/lib/dpkg/info/hl1450lpr.postrm
However, I'll note that I do not understand your premise, you say you do not want to uninstall anything and then proceed to show how you are trying to uninstall something:
bobltx wrote:
Fri Oct 18, 2019 8:53 am
I have a package, hl1450lpr:i386, which is marked red in Package Manager for removal and it is preventing me from doing any updates. If I try to Unmark it immediately it goes back to red again. The Brother HL1450 printer on this machine is working as is the HP Deskjet 5550 so I don't really want to uninstall
anything. I have tried to remove it thus:
Shouldn't you have asked how not to remove it? Anyway, what's done is done I guess, you can always reinstall it should it end up being needed.
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

bobltx
Level 1
Level 1
Posts: 9
Joined: Wed Jun 29, 2016 2:54 am
Location: West Wales, UK

Re: Package 'stuck' in Package Manager.

Post by bobltx » Wed Nov 06, 2019 8:19 am

gm10 you're a genius :-)

Problem now solved thanks to you.
What I didn't want to uninstall were the printer 'drivers' having had some hassle getting both printers up and running. The offending 'hl1450lpr:i386' was marked for removal and highlighted in red in synaptic but would not go whatever we tried, and no updates could be installed.

Just done an update and everything listed downloaded and installed OK, I now might do an OS update. Also both printers are still working fine so it was a not needed file.

Thank you all very much for you help.
Linux Mint 18.2 Sonya on AMD A10-7800 Radeon R7,
12 Compute Cores 4C+8G × 4 with 8GB RAM.

gm10
Level 19
Level 19
Posts: 9820
Joined: Thu Jun 21, 2018 5:11 pm

Re: Package 'stuck' in Package Manager.

Post by gm10 » Wed Nov 06, 2019 8:25 am

I may well be, but in this case I may just have been the only one who actually read the error message you received, I'm not sure that alone qualifies me. :lol:

Anyway, happy to help. ;) :mrgreen:
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

Post Reply

Return to “Software & Applications”