"Dependency resolution failed"

Asked by Pat

I keep getting messages "Dependency Resolution Failed" I don't know what to do. Tells me to use Synaptic or aptitude. But I don't know how. I can get no updates now. Have been using Kubuntu for 1 year now with no problems except for losing all audio. But I can live with that. Otherwise working great.
Can you please help? "Dependency resolution failed" messages keep popping up on my screen about every ten minutes.
I am thinking this must be a major problem.
I have never seen this message before. It also says: "A package dependency could not be found."

How can I repair this problem? Do you have suggestions?

Can I re-install Kubuntu on my hard drive and still keep all of my old data?

Hope you can help.
Best regards
Pat L.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu installation-guide Edit question
Assignee:
No assignee Edit question
Solved by:
Pat
Solved:
Last query:
Last reply:
Revision history for this message
Pat (usa104) said :
#1

Message says: "There are broken dependencies in my system".

Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#2

Hi,

First please make sure to close all open programs, including all package managers like Synaptic, Add/remove programs, etc ...

Then please try this procedure:

Step 1: Open Terminal from "Applications->Accessories->
Terminal"

Step 2: Please COPY-PASTE each line below into the Terminal then hit <enter> after each line)

sudo cp -arf /var/lib/dpkg /var/lib/dpkg.backup
sudo cp /var/lib/dpkg/status-old /var/lib/dpkg/status
sudo cp /var/lib/dpkg/available-old /var/lib/dpkg/available
sudo rm -rf /var/lib/dpkg/updates/*
sudo rm -rf /var/lib/apt/lists
sudo mkdir /var/lib/apt/lists
sudo mkdir /var/lib/apt/lists/partial
LANG=C;sudo aptitude clean
LANG=C;sudo aptitude autoclean
LANG=C;sudo apt-get update
sudo dpkg --clear-avail
sudo dpkg --configure -a
LANG=C;sudo aptitude install -f
LANG=C;sudo aptitude update
LANG=C;sudo aptitude dist-upgrade

Step 3: Please post results (copy/paste terminal output from each command) on this thread

Hope it helps,

Regards,

Mark

Revision history for this message
Pat (usa104) said :
#3

Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Writing extended state information... Done

liz@liz:~$ LANG=C;sudo aptitude autoclean
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Freed 0B of disk space

liz@liz:~$ LANG=C;sudo apt-get update
Get:1 http://security.ubuntu.com karmic-security Release.gpg [189B]
Get:2 http://archive.canonical.com jaunty Release.gpg [189B]
Get:3 http://security.ubuntu.com karmic-security Release [44.1kB]
Get:4 http://archive.canonical.com jaunty Release [10.5kB]
Get:5 http://archive.canonical.com jaunty/partner Packages [4142B]
Get:6 http://security.ubuntu.com karmic-security/main Packages [95.6kB]
Get:7 http://archive.canonical.com jaunty/partner Sources [1731B]
Get:8 http://security.ubuntu.com karmic-security/restricted Packages [14B]
Get:9 http://security.ubuntu.com karmic-security/main Sources [28.5kB]
Get:10 http://security.ubuntu.com karmic-security/restricted Sources [14B]
Get:11 http://security.ubuntu.com karmic-security/universe Packages [51.1kB]
Get:12 http://security.ubuntu.com karmic-security/universe Sources [8743B]
Get:13 http://security.ubuntu.com karmic-security/multiverse Packages [1666B]
Get:14 http://security.ubuntu.com karmic-security/multiverse Sources [577B]
Get:15 http://us.archive.ubuntu.com karmic Release.gpg [189B]
Get:16 http://us.archive.ubuntu.com karmic-updates Release.gpg [189B]
Get:17 http://us.archive.ubuntu.com jaunty-backports Release.gpg [189B]
Get:18 http://us.archive.ubuntu.com karmic-proposed Release.gpg [189B]
Get:19 http://us.archive.ubuntu.com karmic-backports Release.gpg [189B]
Get:20 http://us.archive.ubuntu.com karmic Release [65.9kB]
Get:21 http://us.archive.ubuntu.com karmic-updates Release [44.1kB]
Get:22 http://us.archive.ubuntu.com jaunty-backports Release [49.6kB]
Get:23 http://us.archive.ubuntu.com karmic-proposed Release [44.1kB]
Get:24 http://us.archive.ubuntu.com karmic-backports Release [37.1kB]
Get:25 http://us.archive.ubuntu.com karmic/main Packages [1353kB]
Get:26 http://us.archive.ubuntu.com karmic/restricted Packages [7971B]
Get:27 http://us.archive.ubuntu.com karmic/main Sources [640kB]
Get:28 http://us.archive.ubuntu.com karmic/restricted Sources [3270B]
Get:29 http://us.archive.ubuntu.com karmic/universe Packages [5133kB]
Get:30 http://us.archive.ubuntu.com karmic/universe Sources [2795kB]
Get:31 http://us.archive.ubuntu.com karmic/multiverse Packages [190kB]
Get:32 http://us.archive.ubuntu.com karmic/multiverse Sources [116kB]
Get:33 http://us.archive.ubuntu.com karmic-updates/main Packages [210kB]
Get:34 http://us.archive.ubuntu.com karmic-updates/restricted Packages [14B]
Get:35 http://us.archive.ubuntu.com karmic-updates/main Sources [62.5kB]
Get:36 http://us.archive.ubuntu.com karmic-updates/restricted Sources [14B]
Get:37 http://us.archive.ubuntu.com karmic-updates/universe Packages [128kB]
Get:38 http://us.archive.ubuntu.com karmic-updates/universe Sources [30.4kB]
Get:39 http://us.archive.ubuntu.com karmic-updates/multiverse Packages [10.1kB]
Get:40 http://us.archive.ubuntu.com karmic-updates/multiverse Sources [4598B]
Get:41 http://us.archive.ubuntu.com jaunty-backports/main Packages [61.8kB]
Get:42 http://us.archive.ubuntu.com jaunty-backports/restricted Packages [14B]
Get:43 http://us.archive.ubuntu.com jaunty-backports/universe Packages [38.4kB]
Get:44 http://us.archive.ubuntu.com jaunty-backports/multiverse Packages [14B]
Get:45 http://us.archive.ubuntu.com karmic-proposed/restricted Packages [14B]
Get:46 http://us.archive.ubuntu.com karmic-proposed/main Packages [107kB]
Get:47 http://us.archive.ubuntu.com karmic-proposed/multiverse Packages [1272B]
Get:48 http://us.archive.ubuntu.com karmic-proposed/universe Packages [16.2kB]
Get:49 http://us.archive.ubuntu.com karmic-backports/restricted Packages [14B]
Get:50 http://us.archive.ubuntu.com karmic-backports/main Packages [67.7kB]
Get:51 http://us.archive.ubuntu.com karmic-backports/multiverse Packages [14B]
Get:52 http://us.archive.ubuntu.com karmic-backports/universe Packages [21.1kB]
Fetched 11.5MB in 2min 36s (73.2kB/s)
Reading package lists... Done

iz@liz:~$ LANG=C;sudo aptitude install -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
Need to get 0B of archives. After unpacking 0B will be used.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done

liz@liz:~$ LANG=C;sudo aptitude update
[sudo] password for liz:
Hit http://security.ubuntu.com karmic-security Release.gpg
Hit http://archive.canonical.com jaunty Release.gpg
Hit http://security.ubuntu.com karmic-security Release
Hit http://archive.canonical.com jaunty Release
Hit http://security.ubuntu.com karmic-security/main Packages
Hit http://archive.canonical.com jaunty/partner Packages
Hit http://security.ubuntu.com karmic-security/restricted Packages
Hit http://security.ubuntu.com karmic-security/main Sources
Hit http://archive.canonical.com jaunty/partner Sources
Hit http://security.ubuntu.com karmic-security/restricted Sources
Hit http://security.ubuntu.com karmic-security/universe Packages
Hit http://security.ubuntu.com karmic-security/universe Sources
Hit http://security.ubuntu.com karmic-security/multiverse Packages
Hit http://security.ubuntu.com karmic-security/multiverse Sources
Hit http://us.archive.ubuntu.com karmic Release.gpg
Hit http://us.archive.ubuntu.com karmic-updates Release.gpg
Hit http://us.archive.ubuntu.com jaunty-backports Release.gpg
Hit http://us.archive.ubuntu.com karmic-proposed Release.gpg
Hit http://us.archive.ubuntu.com karmic-backports Release.gpg
Hit http://us.archive.ubuntu.com karmic Release
Hit http://us.archive.ubuntu.com karmic-updates Release
Hit http://us.archive.ubuntu.com jaunty-backports Release
Hit http://us.archive.ubuntu.com karmic-proposed Release
Hit http://us.archive.ubuntu.com karmic-backports Release
Hit http://us.archive.ubuntu.com karmic/main Packages
Hit http://us.archive.ubuntu.com karmic/restricted Packages
Hit http://us.archive.ubuntu.com karmic/main Sources
Hit http://us.archive.ubuntu.com karmic/restricted Sources
Hit http://us.archive.ubuntu.com karmic/universe Packages
Hit http://us.archive.ubuntu.com karmic/universe Sources
Hit http://us.archive.ubuntu.com karmic/multiverse Packages
Hit http://us.archive.ubuntu.com karmic/multiverse Sources
Hit http://us.archive.ubuntu.com karmic-updates/main Packages
Hit http://us.archive.ubuntu.com karmic-updates/restricted Packages
Hit http://us.archive.ubuntu.com karmic-updates/main Sources
Hit http://us.archive.ubuntu.com karmic-updates/restricted Sources
Hit http://us.archive.ubuntu.com karmic-updates/universe Packages
Hit http://us.archive.ubuntu.com karmic-updates/universe Sources
Hit http://us.archive.ubuntu.com karmic-updates/multiverse Packages
Hit http://us.archive.ubuntu.com karmic-updates/multiverse Sources
Hit http://us.archive.ubuntu.com jaunty-backports/main Packages
Hit http://us.archive.ubuntu.com jaunty-backports/restricted Packages
Hit http://us.archive.ubuntu.com jaunty-backports/universe Packages
Hit http://us.archive.ubuntu.com jaunty-backports/multiverse Packages
Hit http://us.archive.ubuntu.com karmic-proposed/restricted Packages
Hit http://us.archive.ubuntu.com karmic-proposed/main Packages
Hit http://us.archive.ubuntu.com karmic-proposed/multiverse Packages
Hit http://us.archive.ubuntu.com karmic-proposed/universe Packages
Hit http://us.archive.ubuntu.com karmic-backports/restricted Packages
Hit http://us.archive.ubuntu.com karmic-backports/main Packages
Hit http://us.archive.ubuntu.com karmic-backports/multiverse Packages
Hit http://us.archive.ubuntu.com karmic-backports/universe Packages
Reading package lists... Done

liz@liz:~$ LANG=C;sudo aptitude dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
The following packages are BROKEN:
  libpq5
The following packages will be upgraded:
  libavformat52 libpostproc51 tzdata tzdata-java
5 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 1730kB of archives. After unpacking 8192B will be used.
The following packages have unmet dependencies:
  libpq5: Depends: libkrb53 (>= 1.6.dfsg.2) but it is not installable
The following actions will resolve these dependencies:

Keep the following packages at their current version:
libpq5 [8.4.3-0ubuntu9.10 (now)]

Score is 120

Accept this solution? [Y/n/q/?] Y
The following packages will be upgraded:
  libavformat52 libpostproc51 tzdata tzdata-java
4 packages upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
Need to get 1601kB of archives. After unpacking 0B will be used.
Do you want to continue? [Y/n/?] Y
Writing extended state information... Done
Get:1 http://us.archive.ubuntu.com karmic-updates/main tzdata-java 2010i-0ubuntu0.9.10 [144kB]
Get:2 http://us.archive.ubuntu.com karmic-updates/main tzdata 2010i-0ubuntu0.9.10 [679kB]
Get:3 http://us.archive.ubuntu.com karmic-updates/main libavformat52 4:0.5+svn20090706-2ubuntu2.2 [708kB]
Get:4 http://us.archive.ubuntu.com karmic-updates/main libpostproc51 4:0.5+svn20090706-2ubuntu2.2 [69.8kB]
Fetched 1601kB in 13s (118kB/s)
Preconfiguring packages ...
(Reading database ... 238326 files and directories currently installed.)
Preparing to replace tzdata-java 2010h-0ubuntu0.9.10 (using .../tzdata-java_2010i-0ubuntu0.9.10_all.deb) ...
Unpacking replacement tzdata-java ...
Preparing to replace tzdata 2010h-0ubuntu0.9.10 (using .../tzdata_2010i-0ubuntu0.9.10_all.deb) ...
Unpacking replacement tzdata ...
Setting up tzdata (2010i-0ubuntu0.9.10) ...

Current default time zone: 'America/Chicago'
Local time is now: Sat May 1 17:44:15 CDT 2010.
Universal Time is now: Sat May 1 22:44:15 UTC 2010.
Run 'dpkg-reconfigure tzdata' if you wish to change it.

(Reading database ... 238326 files and directories currently installed.)
Preparing to replace libavformat52 4:0.5+svn20090706-2ubuntu2.1 (using .../libavformat52_4%3a0.5+svn20090706-2ubuntu2.2_i386.deb) ...
Unpacking replacement libavformat52 ...
Preparing to replace libpostproc51 4:0.5+svn20090706-2ubuntu2.1 (using .../libpostproc51_4%3a0.5+svn20090706-2ubuntu2.2_i386.deb) ...
Unpacking replacement libpostproc51 ...
Setting up tzdata-java (2010i-0ubuntu0.9.10) ...
Setting up libavformat52 (4:0.5+svn20090706-2ubuntu2.2) ...

Setting up libpostproc51 (4:0.5+svn20090706-2ubuntu2.2) ...

Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done

Current status: 1 update [-4].

Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#4

The Terminal output seems to indicate that your package manager is working correctly now.

Revision history for this message
Pat (usa104) said :
#5

Thank you very much Mr. Rijkenberg!

Would you please share with me the possible reason that
this problem occurred, and also what exactly was required to
repair the problem.
Did I somehow cause this problem on my computer?

Best regards,

Pat L.

Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#6

Impossible to say what exactly caused the issue to occur. I do not have the history of actions taken on your pc before you received the error ""Dependency resolution failed"

The first message I sent you (and that you followed) contains the procedure for fixing package manager issues (like this one) in the future.