2

I'm running into the following error when I'm installing any package on 12.04.

Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
 postgresql-client-9.1 : Breaks: postgresql-9.1 (< 9.1.7-0ubuntu12.04) but 9.1.6-1~precise2 is installed
E: Unmet dependencies. Try using -f.

Tried following commands,

sudo apt-get autoremove
sudo apt-get autorclean
sudo apt-get install -f
sudo apt-get purge postgresql
sudo apt-get purge postgresql-client-9.1
sudo apt-get autoremove --purge postgresql-client-9.1
sudo apt-get autoremove --purge postgresql
sudo apt-get remove --dry-run postgresql
sudo apt-get update

etc. But none of this could save me. Any idea?

2
  • I have seen those similar post. But didn't help.
    – sjn
    Dec 27, 2012 at 7:29
  • Yes I might have scratched only the surface of methods from that answer. To be honest, I was bit frustrated seeing this issue popped up. I've been using Ubuntu exclusively for the past 3+ years, and wanted these things to be smooth; has been very pleasant for most of the time. But anyway I got past the issue by removing the packages using 'dpkg -r' itself (Answer added)
    – sjn
    Dec 29, 2012 at 2:06

3 Answers 3

1

I had a similar problem , and this solved it.

add-apt-repository ppa:pitti/postgresql
apt-get purge postgresql*
apt-get install update && apt-get install upgrade
apt-get install postgresql
apt-get update && apt-get upgrade
1

Got rid of these error by removing those Postgresql (and client-9.1) using 'dpkg -r' directly.

sudo dpkg -r postgresql
sudo dpkg -r postgresql-client-9.1
0

I had this problem which was a result of version incompatibility between binaries in the standard Ubuntu repository and in pitti. I resolved it by removing postgresql-client metapackage. Hope this helps.

1
  • Got the same error while removing postgresql-client unfortunately.
    – sjn
    Dec 29, 2012 at 1:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .