Packages have unmet dependencies
Start with removing obsolete Point Cloud Library PPA with
sudo add-apt-repository -r ppa:v-launchpad-jochen-sprickerhof-de/pcl
sudo apt-get update
Save the lists of all installed applications to your home folder:
dpkg --get-selections > ~/dpkg_selections.txt
dpkg -l > ~/dpkg_l.txt
to restore them after fixing existing problems.
You can try with Aptitude:
sudo apt-get install aptitude
sudo aptitude safe-upgrade
But it may not help, as your system is seriously broken, so we need to fix it step-by-step. Something like:
sudo aptitude reinstall ubuntu-minimal
sudo aptitude reinstall ubuntu-standard
sudo aptitude reinstall ubuntu-system-service
sudo apt-get install -f
sudo apt-get dist-upgrade
and so on.
Related videos on Youtube
soo kin wah
Updated on September 18, 2022Comments
-
soo kin wah over 1 year
Yesterday i have receive notification of upgrading my 16.04 to 18.04.
In the process, it has mentioned that i have some packages that have unmet dependencies.
after conduct
sudo apt-get -f install
, i obtained the following issue and hope everyone may guide me.[UPDATED] Result of apt-get update
soo@laptop-soo:~$ sudo apt-get update Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease Hit:2 http://dl.google.com/linux/chrome/deb stable Release Ign:4 http://linux.dropbox.com/ubuntu xenial InRelease Hit:5 http://ppa.launchpad.net/notepadqq-team/notepadqq/ubuntu xenial InRelease Hit:6 http://my.archive.ubuntu.com/ubuntu xenial InRelease Get:7 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB] Hit:8 http://packages.ros.org/ros/ubuntu xenial InRelease Hit:9 http://linux.dropbox.com/ubuntu xenial Release Get:10 http://my.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB] Hit:12 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu xenial InRelease Get:13 http://my.archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB] Fetched 325 kB in 2s (159 kB/s) Reading package lists... Done
[UPDATED] Result apt-get -f install : https://pastebin.ubuntu.com/p/YjWgzT9dmG/
[UPDATED] Result sudo apt-get dist-upgrade : https://pastebin.ubuntu.com/p/33H4Rpfsm3/
[UPDATED] apt-cache policy python3
soo@laptop-soo:~$ apt-cache policy python3 python3: Installed: (none) Candidate: 3.5.1-3 Version table: 3.5.1-3 500 500 http://my.archive.ubuntu.com/ubuntu xenial/main i386 Packages
[UPDATED : sudo aptitude safe-upgrade]
soo@laptop-soo:~$ sudo aptitude safe-upgrade Resolving dependencies... Unable to resolve dependencies for the upgrade: no solution found. Unable to safely resolve dependencies, try running with --full-resolver.
[UPDATED : sudo aptitude safe-upgrade --full-resolver] : https://pastebin.ubuntu.com/p/9DYmHHTxs6/ If i reply + (means install) for this output, it show the following message which seems like very dangerous to do anything..
The following ESSENTIAL packages will be BROKEN by this action: apt : Depends: gpgv but it is not going to be installed. or gpgv2 but it is not going to be installed. Depends: gnupg but it is not going to be installed. or gnupg2 but it is not going to be installed. dpkg : Conflicts: dpkg:amd64 but 1.18.4ubuntu1.5 is installed. dpkg:amd64 : Conflicts: dpkg but 1.18.4ubuntu1.5 is to be installed. tar : Conflicts: tar:amd64 but 1.28-2.1ubuntu0.1 is installed. tar:amd64 : Conflicts: tar but 1.28-2.1ubuntu0.1 is to be installed. WARNING: Performing this action will probably cause your system to break! Do NOT continue unless you know EXACTLY what you are doing! To continue, type the phrase "I am aware that this is a very bad idea":
This image show the setting for my Software and Update
Thank you so much for your attention.. Sorry for troubling you all :)
-
soo kin wah about 5 yearsThank you for the instant guidance ! I will do it right away ! Thank you :D
-
user535733 about 5 years"Held broken packages" means you have introduced packages (usually from some non-Ubuntu PPA or other non-Ubuntu source) that are incompatible with your release of Ubuntu. There is no magic incantation to fix it - you must understand the problem in order to know the correct package(s) to remove.
-
N0rbert about 5 yearsThis looks very strange. Could you please check the settings of your repositories in
software-properties-gtk
and select Main server here? See this Q&A for details. For me it seems that you use a not full set of repositories or they are outdated. -
soo kin wah about 5 years@user535733, i have go through few article or forum about this and i have tried several methods to solve it.. but in my case, it seems like very complicated compare to those.. :(
-
soo kin wah about 5 years@N0rbert, Noted. I have changed it to main server. However, it does not help and the issue remains the same..
-
N0rbert about 5 years@sookinwah Aptitude may help. You can try
sudo aptitude safe-upgrade
. -
soo kin wah about 5 yearsThank you @N0rbert for willing to guide me patiently. I have tried 'sudo aptitude safe-upgrade' but no solution is outputted and i tried 'sudo aptitude safe-upgrade --full-resolver'. This method with full resolver does provide a solution with its end asking we to install it or not. When i choose install (replied with + symbol), it said it may cause the system to break.. should i proceed ?
-
N0rbert about 5 yearsWe do not know the cause of system breakage. Save the lists of all applications with
dpkg
(see this part in updated answer). As first step I can recommend to reinstallubuntu-minimal
,ubuntu-standard
andubuntu-system-service
withaptitude
. Then retry withaptitude safe-upgrade
.
-
-
soo kin wah about 5 yearsThank you so much for the rapid response. All the steps go smoothly except 'sudo apt-get dist-upgrade' it show the E: Unmet dependencies. Try using -f. at its end. Similar result for Result of apt-get upgrade, apt-get -f install, sudo apt-get -o Debug::pkgProblemResolver=yes dist-upgrade
-
N0rbert about 5 yearsPlease update your question with latest information (after disabling PPA)). Try
sudo apt-get install -f
. -
soo kin wah about 5 yearsI have updated the question.
-
N0rbert about 5 years@sookinwah please update all outputs in your question -
sudo apt-get update
,sudo apt-get install -f
,sudo apt-get dist-upgrade
and addapt-cache policy python3
requested by user535733. -
soo kin wah about 5 years@user535733, I have included your suggestion's output. Thanks for the help! However, outputs for sudo apt-get install -f and sudo apt-get dist-upgrade are not fully show in above due to words limitation.
-
soo kin wah about 5 yearsthank you so much for the updates and sorry for the slow response.. When i 'sudo aptitude reinstall ubuntu-minimal', i get the following response. Should i proceed ? pastebin.ubuntu.com/p/sNnyS4tV2B
-
N0rbert about 5 yearsThen try to install GPG first with
sudo aptitude reinstall gpgv gnupg
first. -
soo kin wah about 5 yearsthanks for your follow up. This method able to solve the problem slowly. However, i have decided to format the partition and reinstall everything. Right now it is working as usual xD