Reputation: 27
I have virtualbox with Debian Wheezy. I'm trying to install Postgresql 9.2 on it. When I trying do it by this instruction i have next:
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-9.2 : Depends: postgresql-common (>= 135~) but it is not going to be installed
Depends: ssl-cert but it is not installable
E: Unable to correct problems, you have held broken packages.
When I try to install postgresql-common:
apt-get install postgresql-common
I got next:
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-common : Depends: ssl-cert (>= 1.0.11) but it is not installable
E: Unable to correct problems, you have held broken packages
When I try to install ssl-cert:
apt-get install ssl-cert
I got next:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package ssl-cert is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'ssl-cert' has no installation candidate
I'm novice in Linux, please help me install Postgresql 9.2
Upvotes: 0
Views: 4331
Reputation: 31
Installing ssl-cert worked when I added these repos to sources.list (/etc/apt/):
deb http://ftp.de.debian.org/debian/ wheezy main non-free contrib
deb-src http://ftp.de.debian.org/debian/ wheezy main non-free contrib
then:
apt-get update
aptitude install ssl-cert
aptitude install postgresql-common
aptitude install postgresql-9.2
Upvotes: 3
Reputation: 5126
Same problem happen to me. This is solution for me:
1. Add official repository
$ echo "deb http://apt.postgresql.org/pub/repos/apt/ wheezy-pgdg main" >> /etc/apt/sources.list
More info here https://wiki.postgresql.org/wiki/Apt
2. Update aptitude's cache
$ apt-get update
3. You can see different versions of "postgresql-common" by running
$ aptitude versions postgresql-common
Output is like this:
Package postgresql-common:
p 134wheezy3 stable
p 147.pgdg70+1 wheezy-pgdg
So we just have to pick a right source
4. Install packages
$ aptitude install postgresql-common postgresql-9.2 libpq-dev -t wheezy-pgdg
Upvotes: 2
Reputation: 8910
I have to do the following to install 9.1 on squeeze:
sudo apt-get -t squeeze-backports install libpq5 postgresql-common
sudo apt-get install postgresql-9.1 postgresql-client-9.1
Maybe something similar but for wheezey is needed here. I don't currently run wheezey so I can't test it out. Hope this helps.
Upvotes: 1