You are not logged in.

#1 2020-01-16 17:03:32

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

[classic]E: Unable to correct problems, you have held broken packages.

Greetings Fellow Penguins

I've came across a very basic recurrent obstacle which I've been unable to solve despite my investigation on linux forums. Therefore, I decided to action your skills, knowledge, experience and good typing will, whatever it might be.

I've been unsuccessfully attempting to install software using apt-get. The error I get by installing many programs is the classic:

E: Unable to correct problems, you have held broken packages.

Which I've been unable to correct.

In advance, my sincere apologies for any mistakes I might be threading as this is my first participation/post in bunsenlabs forums.

So here's an example while I try to install postgresql.

sudo apt-get install -f postgresql
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 postgresql : Depends: postgresql-12 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

#always #noobing #neverLeavingLinuxBehind

Offline

#2 2020-01-16 17:10:23

iMBeCil
WAAAT?
From: Edrychwch o'ch cwmpas
Registered: 2015-09-29
Posts: 767

Re: [classic]E: Unable to correct problems, you have held broken packages.

1. Did you do

$ sudo apt update
$ sudo apt upgrade   # or $ sudo apt dist-upgrade

beforehand? If not, please do.

Please post output of:

$ apt-cache policy postgresql postgresql-12
$ apt-cache policy

Possible solution might be

$ sudo apt install -f

but be careful, if this command wants to do 'too much' (for example, delete packages; in this case, please post output of this command, and for the time being select 'N').

Last edited by iMBeCil (2020-01-16 17:21:13)


Postpone all your duties; if you die, you won't have to do them ..

Offline

#3 2020-01-16 17:14:43

iMBeCil
WAAAT?
From: Edrychwch o'ch cwmpas
Registered: 2015-09-29
Posts: 767

Re: [classic]E: Unable to correct problems, you have held broken packages.

kyw5lien wrote:

In advance, my sincere apologies for any mistakes I might be threading as this is my first participation/post in bunsenlabs forums.

Ah, no need for an apology, you did everything OK wink except possibly specify what distro are you using, and if you have heavily modified something like sources.list or similar ... I implicitly assume you are using vanilla BunsenLabs.


Postpone all your duties; if you die, you won't have to do them ..

Offline

#4 2020-01-16 17:53:57

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

iMBeCil wrote:

1. Did you do

$ sudo apt update
$ sudo apt upgrade   # or $ sudo apt dist-upgrade

beforehand? If not, please do.

Please post output of:

$ apt-cache policy postgresql postgresql-12
$ apt-cache policy

Possible solution might be

$ sudo apt install -f

but be careful, if this command wants to do 'too much' (for example, delete packages; in this case, please post output of this command, and for the time being select 'N').

Yes previously done

$ sudo apt update
$ sudo apt upgrade
$ sudo apt dist-upgrade

Outputs requested:

$apt-cache policy postgresql postgresql-12

postgresql:
  Installed: (none)
  Candidate: 12+210.pgdg90+1
  Version table:
     12+210.pgdg90+1 500
        500 http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main amd64 Packages
     9.6+181+deb9u3 500
        500 https://deb.debian.org/debian-security stretch/updates/main amd64 Packages
postgresql-12:
  Installed: (none)
  Candidate: 12.1-1.pgdg90+1
  Version table:
     12.1-1.pgdg90+1 500
        500 http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main amd64 Packages

$apt-cache policy 
Package files:
 100 /var/lib/dpkg/status
     release a=now
 500 https://repo.skype.com/deb stable/main amd64 Packages
     release o=. stable,a=stable,n=stable,l=. stable,c=main,b=amd64
     origin repo.skype.com
 500 http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main amd64 Packages
     release o=apt.postgresql.org,a=stretch-pgdg,n=stretch-pgdg,l=PostgreSQL for Debian/Ubuntu repository,c=main,b=amd64
     origin apt.postgresql.org
 500 https://deb.opera.com/opera-stable stable/non-free amd64 Packages
     release o=Opera Software AS,a=stable,n=stable,l=The Opera web browser,c=non-free,b=amd64
     origin deb.opera.com
 500 http://repo.mysql.com/apt/debian stretch/mysql-tools-preview amd64 Packages
     release o=MySQL,n=stretch,l=MySQL,c=mysql-tools-preview,b=amd64
     origin repo.mysql.com
 500 http://repo.mysql.com/apt/debian stretch/mysql-tools amd64 Packages
     release o=MySQL,n=stretch,l=MySQL,c=mysql-tools,b=amd64
     origin repo.mysql.com
 500 http://repo.mysql.com/apt/debian stretch/mysql-8.0 amd64 Packages
     release o=MySQL,n=stretch,l=MySQL,c=mysql-8.0,b=amd64
     origin repo.mysql.com
 500 http://repo.mysql.com/apt/debian stretch/mysql-apt-config amd64 Packages
     release o=MySQL,n=stretch,l=MySQL,c=mysql-apt-config,b=amd64
     origin repo.mysql.com
 100 http://deb.debian.org/debian stretch-backports/non-free amd64 Packages
     release o=Debian Backports,a=stretch-backports,n=stretch-backports,l=Debian Backports,c=non-free,b=amd64
     origin deb.debian.org
 100 http://deb.debian.org/debian stretch-backports/contrib amd64 Packages
     release o=Debian Backports,a=stretch-backports,n=stretch-backports,l=Debian Backports,c=contrib,b=amd64
     origin deb.debian.org
 100 http://deb.debian.org/debian stretch-backports/main amd64 Packages
     release o=Debian Backports,a=stretch-backports,n=stretch-backports,l=Debian Backports,c=main,b=amd64
     origin deb.debian.org
 500 https://pkg.bunsenlabs.org/debian helium/main amd64 Packages
     release o=bunsenlabs,n=helium,l=bunsenlabs,c=main,b=amd64
     origin pkg.bunsenlabs.org
 100 http://pkg.bunsenlabs.org/debian stretch-backports/main amd64 Packages
     release o=bunsenlabs,n=stretch-backports,l=bunsenlabs,c=main,b=amd64
     origin pkg.bunsenlabs.org
 500 https://deb.debian.org/debian-security stretch/updates/non-free amd64 Packages
     release v=9,o=Debian,a=oldstable,n=stretch,l=Debian-Security,c=non-free,b=amd64
     origin deb.debian.org
 500 https://deb.debian.org/debian-security stretch/updates/contrib amd64 Packages
     release v=9,o=Debian,a=oldstable,n=stretch,l=Debian-Security,c=contrib,b=amd64
     origin deb.debian.org
 500 https://deb.debian.org/debian-security stretch/updates/main amd64 Packages
     release v=9,o=Debian,a=oldstable,n=stretch,l=Debian-Security,c=main,b=amd64
     origin deb.debian.org
Pinned packages:

$ sudo apt install -f postgresql
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
postgresql : Depends: postgresql-12 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Last edited by kyw5lien (2020-01-16 17:54:35)

Offline

#5 2020-01-16 17:57:11

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

iMBeCil wrote:
kyw5lien wrote:

In advance, my sincere apologies for any mistakes I might be threading as this is my first participation/post in bunsenlabs forums.

Ah, no need for an apology, you did everything OK wink except possibly specify what distro are you using, and if you have heavily modified something like sources.list or similar ... I implicitly assume you are using vanilla BunsenLabs.

$ cat /etc/os-release
ANSI_COLOR="0;34"
BUG_REPORT_URL="https://forums.bunsenlabs.org/viewforum.php?id=14"
HOME_URL="https://www.bunsenlabs.org"
ID="bunsenlabs"
ID_LIKE="debian"
NAME="BunsenLabs GNU/Linux"
PRETTY_NAME="BunsenLabs GNU/Linux 9.8 (Helium)"
SUPPORT_URL="https://forums.bunsenlabs.org"
VERSION="9.8 (Helium)"
VERSION_ID="9.8"

Offline

#6 2020-01-16 18:27:27

brontosaurusrex
Middle Office
Registered: 2015-09-29
Posts: 2,039
Website

Re: [classic]E: Unable to correct problems, you have held broken packages.

Sometimes I aptitude

sudo aptitude install myNewPackage

again, careful.

Offline

#7 2020-01-16 18:41:25

iMBeCil
WAAAT?
From: Edrychwch o'ch cwmpas
Registered: 2015-09-29
Posts: 767

Re: [classic]E: Unable to correct problems, you have held broken packages.

^Well, apparently, along the usual debian repo, you have also enabled 'http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main amd64 Packages' repo (and a few others ...). It seems you wanted the newest version of the postgresql?

I'm afraid it is quite possible that the newest postgresql package (version 12+210) from postgresql repo requires newer libraries than available from debian-stretch repo (there, postgresql package is version 9.6).

I don't know which library(ies) is the culprit, but I don't see simple solution, if there is one at all. Except: either using postgresql version 9.6 from debian-stretch repo, or migrating from debian-stretch to debian-sid ... (The second one is quite a big step, so don't do it without backing up everything.)

Note1: it is seldom good idea to mix repos for particular package. Usually, if there is a package for some program in debian, then one should almost always use this package instead of package from original site (a.k.a upstream).

Note2: I'm not familiar with installing postgresql package from postgresql repo ... perhaps there is certain specialistic solution to your problem, but I don't know it.

Note3: your sources repo list (apt-cache policy) is very similar to FrankenDebian ... please see the explanation there, and Don't suffer from Shiny New Stuff Syndrome on the same site.

Last edited by iMBeCil (2020-01-16 18:44:50)


Postpone all your duties; if you die, you won't have to do them ..

Offline

#8 2020-01-31 05:56:37

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

iMBeCil wrote:

^Well, apparently, along the usual debian repo, you have also enabled 'http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main amd64 Packages' repo (and a few others ...). It seems you wanted the newest version of the postgresql?

I'm afraid it is quite possible that the newest postgresql package (version 12+210) from postgresql repo requires newer libraries than available from debian-stretch repo (there, postgresql package is version 9.6).

I don't know which library(ies) is the culprit, but I don't see simple solution, if there is one at all. Except: either using postgresql version 9.6 from debian-stretch repo, or migrating from debian-stretch to debian-sid ... (The second one is quite a big step, so don't do it without backing up everything.)

Note1: it is seldom good idea to mix repos for particular package. Usually, if there is a package for some program in debian, then one should almost always use this package instead of package from original site (a.k.a upstream).

Note2: I'm not familiar with installing postgresql package from postgresql repo ... perhaps there is certain specialistic solution to your problem, but I don't know it.

Note3: your sources repo list (apt-cache policy) is very similar to FrankenDebian ... please see the explanation there, and Don't suffer from Shiny New Stuff Syndrome on the same site.

Maybe I have not explained it clearly.
It states I have held broken packages on pretty much everything I try to install.

Can't even run bl-welcome properly without getting failed install message due to some reason.

Is there a possibility the version I downloaded is unstable or inappropriate to my machine?

Thanks in advance.

Offline

#9 2020-01-31 06:13:09

damo
....moderator....
Registered: 2015-08-20
Posts: 6,044

Re: [classic]E: Unable to correct problems, you have held broken packages.

kyw5lien wrote:

...

Maybe I have not explained it clearly.
It states I have held broken packages on pretty much everything I try to install.

Can't even run bl-welcome properly without getting failed install message due to some reason.

Is there a possibility the version I downloaded is unstable or inappropriate to my machine?

Thanks in advance.

@iMBeCil explained it quite clearly: you have created a "FrankenDebian" system and have incompatible versions mixed together.

'bl-welcome' is trying to update, and can't, because of the version clashes. When you ran it the first time you had to answer "I understand" when warned about the dangers of mixing sources.


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#10 2020-01-31 06:22:09

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

$ sudo apt-get install chromium
[sudo] password for kyw5lien: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 chromium : Depends: libminizip1 (>= 1.1) but it is not installable
            Depends: libre2-3 (>= 20160901) but it is not installable
            Depends: libwebpdemux2 (>= 0.5.1) but it is not installable
E: Unable to correct problems, you have held broken packages.

I get this 'broken package' message since I first installed it.

If I remove the postgresql source from the repo will that have anything to do with me not able to install Chromium Browser or anything else?

I'm trying to understand what pie has to do with sugar.

Offline

#11 2020-01-31 06:23:22

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

I get this 'broken package' message since I first installed it.

Since I first installed Bunsenlabs that I have not been able to run bl-welcome successfully.

Anyways,

How do I fix it? Any leads/tips?

Offline

#12 2020-01-31 06:49:29

damo
....moderator....
Registered: 2015-08-20
Posts: 6,044

Re: [classic]E: Unable to correct problems, you have held broken packages.

Since I first installed Bunsenlabs

Are you sure you didn't add anything?

If the first non-standard package you installed also brought in dependencies, and those dependencies are also used by other applications, then you will have "broken packages".

You can try removing those lines you have added to your sources list, and remove/autoremove whatever you installed. Then try to replace incompatible packages with versions from Stable.

It is usually easier to reinstall your system sad


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#13 2020-01-31 07:12:08

AndrewSmart
Member
Registered: 2019-06-10
Posts: 22

Re: [classic]E: Unable to correct problems, you have held broken packages.

"held broken packages"... I vaguely remember getting into a similar situation when apt was not able to finish a previous operation (power failure, apt configuration failure, or I made poor choices).

Do you have any packages marked in the "hold" state? Run:

dpkg -l|grep ^h

Also did you try to resolve any previous configuration failures?

sudo apt-get clean
sudo apt-get -f install   #do not write package name, just 'sudo apt-get -f install'
sudo dpkg --configure -a

Last edited by AndrewSmart (2020-01-31 07:17:33)

Offline

#14 2020-01-31 11:38:01

iMBeCil
WAAAT?
From: Edrychwch o'ch cwmpas
Registered: 2015-09-29
Posts: 767

Re: [classic]E: Unable to correct problems, you have held broken packages.

@kyw5lien: I fell you are not listening to what people here (including myself; thanks damo for compliment) are saying ...

A quick check: I just successfully installed both postgresql and chromium on vanilla BL by:

$ sudo apt install postgresql chromium

Therefore, they are installable, and there are no broken, or held packages, nor unmet dependencies, or whatever. However, I didn't add another repos in sources.list.

For some reason, you have added other, non-debian, repos in your sources.list (for whatever reason), and you basically screwed up your entire system. I think it is beyond repair, and the simplest, and by far the fastest, solution is to reinstall BL, and then do not add another repos. At least, not blindly. (Do not forget to make a backup of your files, beforehand.)

The point is: adding non-debian repos is a big no-no, as this is exactly what can happen: you screw your system. Because, you force installation of incompatible pieces (libraries) on your setup, from different (hence incompatible) places (repos), which are not mutually coherent. The term is FrankenDebian, see my previous post about the details.

Also, I don't think AndrewSmart' suggestion will do anything useful ... As long as you have 'foreign' repos enabled, the problem will most likely persist.

Sorry, but that is it.  neutral

Last edited by iMBeCil (2020-01-31 11:40:02)


Postpone all your duties; if you die, you won't have to do them ..

Offline

#15 2020-01-31 12:53:40

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

AndrewSmart wrote:

"held broken packages"... I vaguely remember getting into a similar situation when apt was not able to finish a previous operation (power failure, apt configuration failure, or I made poor choices).

Do you have any packages marked in the "hold" state? Run:

dpkg -l|grep ^h

Negative.

Also did you try to resolve any previous configuration failures?

sudo apt-get clean
sudo apt-get -f install   #do not write package name, just 'sudo apt-get -f install'
sudo dpkg --configure -a

Did run this previously, no effects.

Offline

#16 2020-01-31 12:57:20

kyw5lien
Member
Registered: 2020-01-16
Posts: 8

Re: [classic]E: Unable to correct problems, you have held broken packages.

iMBeCil wrote:

@kyw5lien: I fell you are not listening to what people here (including myself; thanks damo for compliment) are saying ...

A quick check: I just successfully installed both postgresql and chromium on vanilla BL by:

$ sudo apt install postgresql chromium

Therefore, they are installable, and there are no broken, or held packages, nor unmet dependencies, or whatever. However, I didn't add another repos in sources.list.

For some reason, you have added other, non-debian, repos in your sources.list (for whatever reason), and you basically screwed up your entire system. I think it is beyond repair, and the simplest, and by far the fastest, solution is to reinstall BL, and then do not add another repos. At least, not blindly. (Do not forget to make a backup of your files, beforehand.)

The point is: adding non-debian repos is a big no-no, as this is exactly what can happen: you screw your system. Because, you force installation of incompatible pieces (libraries) on your setup, from different (hence incompatible) places (repos), which are not mutually coherent. The term is FrankenDebian, see my previous post about the details.

Also, I don't think AndrewSmart' suggestion will do anything useful ... As long as you have 'foreign' repos enabled, the problem will most likely persist.

Sorry, but that is it.  neutral

Will follow advice & install Bunsenlabs from scratch.
Thanks to all.

Offline

#17 2020-01-31 21:27:51

rbh
Member
From: Sweden/Vasterbotten/Rusfors
Registered: 2016-08-11
Posts: 447

Re: [classic]E: Unable to correct problems, you have held broken packages.

kyw5lien wrote:

Will follow advice & install Bunsenlabs from scratch.
Thanks to all.

Did you have specific need installing postgresql-12 (In debian testing and unsstable)?
If so, you should consider reinstall and upgrade to Debian Bullsey (testing, v. 11).

If you don'tknow why you had postgresql-12, just reinstall and refrain from mixing repos.
I recomend Lithium over helium.


// Regards rbh

Offline

#18 2020-01-31 23:08:06

rbh
Member
From: Sweden/Vasterbotten/Rusfors
Registered: 2016-08-11
Posts: 447

Re: [classic]E: Unable to correct problems, you have held broken packages.

rbh wrote:
kyw5lien wrote:

Will follow advice & install Bunsenlabs from scratch.
Thanks to all.

Did you have specific need installing postgresql-12

Sorry for my delirious post. Was rather unfocused. The real problem was adding repo
http://apt.postgresql.org/pub/repos/apt stretch-pgdg/main.
But postgresql-12 is not in stretch-pgdg...

Was there some good reason for you to use http://apt.postgresql.org?


// Regards rbh

Offline

#19 2020-01-31 23:21:42

AndrewSmart
Member
Registered: 2019-06-10
Posts: 22

Re: [classic]E: Unable to correct problems, you have held broken packages.

iMBeCil wrote:

For some reason, you have added other, non-debian, repos in your sources.list (for whatever reason), and you basically screwed up your entire system. I think it is beyond repair, and the simplest, and by far the fastest, solution is to reinstall BL, and then do not add another repos. At least, not blindly. (Do not forget to make a backup of your files, beforehand.)

The point is: adding non-debian repos is a big no-no, as this is exactly what can happen: you screw your system. Because, you force installation of incompatible pieces (libraries) on your setup, from different (hence incompatible) places (repos), which are not mutually coherent. The term is FrankenDebian, see my previous post about the details.

https://wiki.debian.org/Opera

I don't think that is accurate to advise to never add such repos. I've added Opera, testing, unstable repos, among many others.

Regarding testing/unstable (a release different from the system's), the trick is to press (N) when a package wants to update libc6. Many things in those repos do not require testing/unstable's libc6, so you can find newer packages not available in stable which had not been backported into stable-backports. Yes there is some risk here depending on what it is.

I suspect it is possible to fix the problem in the package management, just a matter of figuring out the issue. Possibly by commenting out said repos as earlier suggested, or by strategically changing apt-pinning to resolve conflicts the solver experiences. But he may find it quicker/easier to just reinstall instead of troubleshoot and read man pages.

This would illuminate if the suspect system indeed suffers from FrankenDebian:

apt-cache policy libc6

Also kyw5lien, when you added the Opera repository and Skype, contrary to using 'stable' as is often written in their respective guides:

deb https://repo.skype.com/deb stable/main

It is better to write the release name you're using (matching the convention you're following in other lines), to avoid packaging problems/conflicts when Debian stable advances:

deb https://repo.skype.com/deb stretch/main

And later update to stable all at once (by changing apt sources.list)... or use whatever strategy you think appropriate.

Last edited by AndrewSmart (2020-01-31 23:36:09)

Offline

#20 2020-01-31 23:59:19

hhh
Meep!
Registered: 2015-09-17
Posts: 9,878
Website

Re: [classic]E: Unable to correct problems, you have held broken packages.

A point is in order here...

AndrewSmart wrote:

I don't think that is accurate to advise to never add such repos. I've added Opera, testing, unstable repos, among many others.

... and his system is broken. Congratulations, he gets to keep the pieces.

We recommend Debian practices because we are an Official Debian Derivative, and Debian says Don't Make A FrankenDebian. Manually create your own backport of the package, but don't just add a repo from Ubuntu. This tutorial needs updating, but it still works...

https://forums.bunsenlabs.org/viewtopic.php?id=58

Your next arguments are just plain old bad conjecture (I suspect? You suspect erroneously), and, by Debian standards, dangerous Linux maintenance recommendations...

Regarding testing/unstable (a release different from the system's), the trick is to press (N) when a package wants to update libc6. Many things in those repos do not require testing/unstable's libc6, so you can find newer packages not available in stable which had not been backported into stable-backports. Yes there is some risk here depending on what it is.

I suspect it is possible to fix the problem in the package management, just a matter of figuring out the issue. Possibly by commenting out said repos as earlier suggested, or by strategically changing apt-pinning to resolve conflicts the solver experiences...

Offline

#21 2020-02-01 02:07:53

AndrewSmart
Member
Registered: 2019-06-10
Posts: 22

Re: [classic]E: Unable to correct problems, you have held broken packages.

hhh wrote:

A point is in order here...
We recommend Debian practices because we are an Official Debian Derivative, and Debian says Don't Make A FrankenDebian. Manually create your own backport of the package, but don't just add a repo from Ubuntu. This tutorial needs updating, but it still works...

It would help if he'd say what guide he was following to understand what he was trying to do.

hhh wrote:

Your next arguments are just plain old bad conjecture (I suspect? You suspect erroneously), and, by Debian standards, dangerous Linux maintenance recommendations...

Regarding testing/unstable (a release different from the system's), the trick is to press (N) when a package wants to update libc6. Many things in those repos do not require testing/unstable's libc6, so you can find newer packages not available in stable which had not been backported into stable-backports. Yes there is some risk here depending on what it is.

I suspect it is possible to fix the problem in the package management, just a matter of figuring out the issue. Possibly by commenting out said repos as earlier suggested, or by strategically changing apt-pinning to resolve conflicts the solver experiences...

This article is a short overview of how to use apt-pinning on Debian and Debian-based distributions (like Ubuntu). Apt-Pinning allows you to use multiple releases (e.g. stable, testing, and unstable) on your system and to specify when to install a package from which release. That way you can run a system based mostly on the stable release, but also install some newer packages from testing or unstable (or third-party repositories).

https://www.howtoforge.com/a-short-intr … pt-pinning

Sometimes it is necessary, to get bleeding edge software packaged as a .deb, without having to get the sources and deal with building it. I expect this is what he was doing with that postgresql repo, wanting version 12 instead of 9 for whatever reason...

I maintain it is likely possible to fix the issue the package management solver is stuck on... if he wishes to troubleshoot that instead of re-installing a vanilla system again.

One thing he could try, for example, is to use apt-pinning to "downgrade" every testing/unstable (non-stable) package to stable all at once! A Debian kosher solution don't you think?

Last edited by AndrewSmart (2020-02-01 02:28:32)

Offline

#22 2020-02-01 05:33:35

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 6,959
Website

Re: [classic]E: Unable to correct problems, you have held broken packages.

AndrewSmart wrote:

One thing he could try, for example, is to use apt-pinning to "downgrade" every testing/unstable (non-stable) package to stable all at once! A Debian kosher solution don't you think?

No.

Apt-pinning is for experienced users, and not often needed by them either. Downgrading packages is dangerous too, and the dpkg manual warns:

man dpkg wrote:

              Warning: At present dpkg does not do any dependency  checking  on
              downgrades  and  therefore  will  not  warn  you if the downgrade
              breaks the dependency  of  some  other  package.  This  can  have
              serious side effects, downgrading essential system components can
              even make your whole system unusable. Use with care.


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), idle Twitterings and GitStuff )

Introduction to the Bunsenlabs Lithium Desktop

Offline

#23 2020-02-02 00:39:11

hhh
Meep!
Registered: 2015-09-17
Posts: 9,878
Website

Re: [classic]E: Unable to correct problems, you have held broken packages.

@Andrew, sources for the tutorial are in the second post of the tutorial...

https://forums.bunsenlabs.org/viewtopic … d=460#p460

Offline

#24 2020-02-02 02:12:59

stevep
MX Linux Developer
Registered: 2016-08-08
Posts: 381

Re: [classic]E: Unable to correct problems, you have held broken packages.

Maybe my eyes are bad, and I missed it, but I didn't see the standard Debian Stretch repo in your apt policy results--just backports (also not a good idea to leave enabled) and security updates.

If you can install inxi, either via apt or manually, "inxi -r" gives a much more readable list of your repos, IMHO.

Offline

#25 2020-02-02 12:59:01

iMBeCil
WAAAT?
From: Edrychwch o'ch cwmpas
Registered: 2015-09-29
Posts: 767

Re: [classic]E: Unable to correct problems, you have held broken packages.

AndrewSmart wrote:

I don't think that is accurate to advise to never add such repos. I've added Opera, testing, unstable repos, among many others.
...

Quite, I might put it too harsh ... I myself also have a few non-debian repos added (skype, picotech, stevep-palemoon@opensus), but I understood what OP's errors mean, and what can be done about it, while OP didn't know. (Now I hope (sh)he understand what is going under the hood.) In this respect I agree with hhh.

Rant: in particular, I'm not afraid adding - for example - skype, because I'm sure MS has had compiled almost everything statically, and packaged needed libraries, too. OTOH, adding postgresql repo (or Ubuntu repo, for that matter), implies that packagers rely on existence of common libraries ... and 'apt', attempting to be as automatic as possible, will pull missing ones, possibly overwriting existing (good) ones ... Generally speaking, or a rule of thumb, a standalone software should be reasonable to add as a repo; non-standalone shouldn't be. And of course, one has to know what he is doing, read messages in terminal, and understand them smile

Last edited by iMBeCil (2020-02-02 13:00:11)


Postpone all your duties; if you die, you won't have to do them ..

Offline

Board footer

Powered by FluxBB