尝试更新postgresql-libs时出错

当我做yum update ,出现以下错误:

 Transaction Check Error: file /usr/lib64/libecpg.so.6.1 from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.x86_64 file /usr/lib64/libecpg_compat.so.3.1 from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.x86_64 file /usr/lib64/libpgtypes.so.3.1 from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.x86_64 file /usr/lib64/libpq.so.5.2 from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.x86_64 file /usr/share/locale/pl/LC_MESSAGES/libpq5-8.4.mo from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.x86_64 file /usr/share/locale/pl/LC_MESSAGES/libpq5-8.4.mo from install of postgresql-libs-8.4.10-1PGDG.rhel5.x86_64 conflicts with file from package postgresql84-libs-8.4.9-1.el5_7.1.i386 

我现在有想法,因为我已经使用yum安装pgsql它可能会发生冲突。

但没关系。

但我不知道如何解决这些问题,我可以更新pgsql库。

有一个类似的问题 ,但这是关于安装i386与x86_64版本。

那么…如何解决这个问题?

编辑

根据要求重新调整百胜:

 repo id repo name status addons CentOS-5 - Addons 0 base CentOS-5 - Base 3,558+8 epel Extra Packages for Enterprise Linux 5 - x86_64 6,808 extras CentOS-5 - Extras 269 ius IUS Community Packages for Enterprise Linux 5 - x86_6 149 kbs-CentOS-Extras CentOS.Karan.Org-EL5 - Stable 0 kbs-CentOS-Misc CentOS.Karan.Org-EL5 - Stable 0 pgdg84 PostgreSQL 8.4 5 - x86_64 161 rpmforge Red Hat Enterprise 5 - RPMforge.net - dag 10,899+1 updates CentOS-5 - Updates 442+24 

它看起来像你安装的postgresql版本是从yum.postgresql.org和yum试图从centos回购更新postgresql。 如果是这种情况,您是否尝试将exclude=postgresql*行添加到/etc/yum.repos.d/CentOS*.repo文件的相应部分?

例如(来自/etc/yum.repos.d/CentOS-Base.repo):

 [base] name=CentOS-$releasever - Base mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os #baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/ gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5 exclude=postgresql* #released updates [updates] name=CentOS-$releasever - Updates mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates #baseurl=http://mirror.centos.org/centos/$releasever/updates/$basearch/ gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5 exclude=postgresql* 

更新它看起来像你的yum repolist输出确认我的预感…你需要告诉百胜不要从CentOS回购安装/更新/使用postgresql84包。 将排除语句添加到CentOS-Base.repo文件的基本和更新部分,您应该设置。

冲突错误通常是由混合存储库引起的。 尝试这个:

 # yum --disablerepo=pgdg84 install postgresql-libs 

我遇到了类似的问题,虽然所有的冲突都是反对的
postgresql84-libs-8.4.6-1PGDG.rhel5.i386

我只使用x86_64,只是删除为我工作的i386库。 你可以试试这个:

yum remove postgresql84-libs-8.4.9-1.el5_7.1.i386

没有任何依赖关系,所以我能够没有问题地移除,之后,yum更新能够在没有错误的情况下完成。