Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm attempting to upgrade PHP from 5.1.6 to at least version 5.2.3 to support an install MediaWiki. I'm running CentOS release 5.5 on x86 architecture.
When I run the 'yum update' command I get the following output
Code:
# yum update
Loaded plugins: fastestmirror, priorities
Determining fastest mirrors
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.user_main(sys.argv[1:], exit_code=True)
File "/usr/share/yum-cli/yummain.py", line 309, in user_main
errcode = main(args)
File "/usr/share/yum-cli/yummain.py", line 178, in main
result, resultmsgs = base.doCommands()
File "/usr/share/yum-cli/cli.py", line 345, in doCommands
self._getTs(needTsRemove)
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 101, in _getTs
self._getTsInfo(remove_only)
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 112, in _getTsInfo
pkgSack = self.pkgSack
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 661, in <lambda>
pkgSack = property(fget=lambda self: self._getSacks(),
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 501, in _getSacks
self.repos.populateSack(which=repos)
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 232, in populateSack
self.doSetup()
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 79, in doSetup
self.ayum.plugins.run('postreposetup')
File "/usr/lib/python2.4/site-packages/yum/plugins.py", line 179, in run
func(conduitcls(self, self.base, conf, **kwargs))
File "/usr/lib/yum-plugins/fastestmirror.py", line 176, in postreposetup_hook
if downgrade_ftp and _len_non_ftp(repo.urls) == 1:
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 676, in <lambda>
urls = property(fget=lambda self: self._geturls(),
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 673, in _geturls
self._baseurlSetup()
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 614, in _baseurlSetup
mirrorurls.extend(self._getMirrorList())
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 1622, in _getMirrorList
fo = urlgrabber.grabber.urlopen(url, proxies=self.proxy_dict)
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 612, in urlopen
return default_grabber.urlopen(url, **kwargs)
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 891, in urlopen
return self._retry(opts, retryfunc, url)
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 852, in _retry
r = apply(func, (opts,) + args, {})
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 890, in retryfunc
return URLGrabberFileObject(url, filename=None, opts=opts)
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 1008, in __init__
self._do_open()
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 1091, in _do_open
fo, hdr = self._make_request(req, opener)
File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 1204, in _make_request
fo = opener.open(req)
File "/usr/lib64/python2.4/urllib2.py", line 364, in open
response = meth(req, response)
File "/usr/lib64/python2.4/urllib2.py", line 471, in http_response
response = self.parent.error(
File "/usr/lib64/python2.4/urllib2.py", line 396, in error
result = self._call_chain(*args)
File "/usr/lib64/python2.4/urllib2.py", line 337, in _call_chain
result = func(*args)
File "/usr/lib64/python2.4/urllib2.py", line 554, in http_error_302
return self.parent.open(new)
File "/usr/lib64/python2.4/urllib2.py", line 358, in open
response = self._open(req, data)
File "/usr/lib64/python2.4/urllib2.py", line 376, in _open
'_open', req)
File "/usr/lib64/python2.4/urllib2.py", line 337, in _call_chain
result = func(*args)
File "/usr/lib64/python2.4/site-packages/M2Crypto/m2urllib2.py", line 82, in https_open
h.request(req.get_method(), req.get_selector(), req.data, headers)
File "/usr/lib64/python2.4/httplib.py", line 810, in request
self._send_request(method, url, body, headers)
File "/usr/lib64/python2.4/httplib.py", line 833, in _send_request
self.endheaders()
File "/usr/lib64/python2.4/httplib.py", line 804, in endheaders
self._send_output()
File "/usr/lib64/python2.4/httplib.py", line 685, in _send_output
self.send(msg)
File "/usr/lib64/python2.4/httplib.py", line 652, in send
self.connect()
File "/usr/lib64/python2.4/site-packages/M2Crypto/httpslib.py", line 47, in connect
self.sock.connect((self.host, self.port))
File "/usr/lib64/python2.4/site-packages/M2Crypto/SSL/Connection.py", line 159, in connect
if not check(self.get_peer_cert(), self.addr[0]):
File "/usr/lib64/python2.4/site-packages/M2Crypto/SSL/Checker.py", line 113, in __call__
fieldName='commonName')
M2Crypto.SSL.Checker.WrongHost: Peer certificate commonName does not match host, expected 204.15.73.243, got 172.24.99.225
The part that sticks out to me is the last line M2Crypto part, might be the issue but I can't decipher if all the text above that is errors or not.
Any ideas on what could be the cause? Yum was working a few months ago when I installed TCL/Expect and there has been no changes to the server that I'm aware of.
Thanks
EDIT: Attaching yum.conf and .repo files
/etc/yum.conf
Code:
[main]
cachedir=/var/cache/yum
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
distroverpkg=redhat-release
tolerant=1
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
# Note: yum-RHN-plugin doesn't honor this.
metadata_expire=1h
# Default.
# installonly_limit = 3
# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
Repo Directory
Code:
# ls -la /etc/yum.repos.d/
total 60
drwxr-xr-x 2 root root 4096 Feb 21 11:45 .
drwxr-xr-x 109 root root 12288 Feb 21 15:00 ..
-rw-r--r-- 1 root root 2311 Jun 22 2010 CentOS-Base.repo
-rw-r--r-- 1 root root 638 Jun 22 2010 CentOS-Media.repo
-rw-r--r-- 1 root root 1032 Oct 4 2005 jpackage.repo
-rw-r--r-- 1 root root 739 Jan 4 2010 mirrors-rpmforge
-rw-r--r-- 1 root root 436 Jan 4 2010 rpmforge.repo
-rw-r--r-- 1 root root 325 Jan 4 2010 rpmforge-testing.repo
-rw-r--r-- 1 root root 828 Apr 17 2010 webtatic.repo
Base CENTOS Repo
Code:
# cat /etc/yum.repos.d/CentOS-Base.repo
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[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
priority=1
#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
priority=1
#packages used/produced in the build but not released
[addons]
name=CentOS-$releasever - Addons
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons
#baseurl=http://mirror.centos.org/centos/$releasever/addons/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras
#baseurl=http://mirror.centos.org/centos/$releasever/extras/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-$releasever - Plus
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus
#baseurl=http://mirror.centos.org/centos/$releasever/centosplus/$basearch/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=2
#contrib - packages by Centos Users
[contrib]
name=CentOS-$releasever - Contrib
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib
#baseurl=http://mirror.centos.org/centos/$releasever/contrib/$basearch/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=2
Last edited by Stuart07; 02-21-2012 at 02:06 PM.
Reason: Adding more files
I'm running CentOS release 5.5 on x86 architecture.
the x86 is the 32 bit OS )
and from this you do not have a 32 bit OS
/usr/lib64/python2.4 ( a 64 bit cent install)
are you trying to NOT install the 64 bit programs and only install the 32 bit code ?
cent also has not supported 5.5 in a long time
The only supported 5 is 5.7 - please upgrade
normally the very first thing i check with a yum and python error is
Python
the version in the cent updates IS REQUIRED in order for yum to work ( and gnome too)
so
Did you by chance change the version of python installed to say 2.6 ?
It is possible to install more than one version
cent5.5 has not gotten the current cent5.7 security fixes so you might want to run "chrootkit" and "rkhunter"
----------------------
and the other thing
you have BOTH
centos.repo
AND
rpmforge.repo
rpmforge-testing.repo
but you NO NOT have "yum-priorities" installed and configured
rpmforge and the centos base repo are INCOMPATIBLE
rpmforge will replace some of the cent os with DIFFERENT versions of software
-- this is plastered allover the place as warnings on the cent wiki and help pages ---
so that might also be the cause
if it is rpmforge that is causing the problem
there is NO EASY fix
it might take a month to straiten out or it might take a day
I ended up installing CentOS 5.7 on another machine. I copied the default yum repositories from the fresh installation and placed them in the repo folder on the old machine, and yum started working again.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.