在 debian wheezy 上安装 postgresql 9.2(在 virtualbox 上)

在 debian wheezy 上安装 postgresql 9.2(在 virtualbox 上)

我有带有 Debian Wheezy 的 virtualbox。我正在尝试在其上安装 Postgresql 9.2。当我尝试这样做时我有下一个指令:

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.

当我尝试安装 postgresql-common 时:

apt-get install postgresql-common

我得到了下一个:

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

当我尝试安装 ssl-cert 时:

apt-get install ssl-cert

我得到了下一个:

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

我是Linux新手,请帮我安装Postgresql 9.2

有我的sources.list

#

# deb cdrom:[Debian GNU/Linux 7.0.0 _Wheezy_ - Official i386 CD Binary-1 201305$

deb cdrom:[Debian GNU/Linux 7.0.0 _Wheezy_ - Official i386 CD Binary-1 20130504$

deb http://security.debian.org/ wheezy/updates main
deb-src http://security.debian.org/ wheezy/updates main

# wheezy-updates, previously known as 'volatile'
# A network mirror was not selected during install.  The following entries
# are provided as examples, but you should amend them as appropriate
# for your mirror of choice.
#
# deb http://ftp.debian.org/debian/ wheezy-updates main
# deb-src http://ftp.debian.org/debian/ wheezy-updates main

答案1

将其添加到您的sources.list

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

确保使用适合您所在位置的镜子。

运行aptitude updateapt-get update并完成安装。

的交互方式aptitude对于解决依赖关系还是蛮有用的。

相关内容