yum--AttributeError: 'module' object has no attribute 'HTTPSHandler'

 [root@dev05 yum]# yum

Traceback (most recent call last):
  File "/usr/bin/yum", line 4, in ?
    import yum
  File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 50, in ?
    import config
  File "/usr/lib/python2.4/site-packages/yum/config.py", line 27, in ?
    from parser import ConfigPreProcessor
  File "/usr/lib/python2.4/site-packages/yum/parser.py", line 3, in ?
    import urlgrabber
  File "/usr/lib/python2.4/site-packages/urlgrabber/__init__.py", line 53, in ?
    from grabber import urlgrab, urlopen, urlread
  File "/usr/lib/python2.4/site-packages/urlgrabber/grabber.py", line 412, in ?
    import keepalive
  File "/usr/lib/python2.4/site-packages/urlgrabber/keepalive.py", line 339, in ?
    class HTTPSHandler(KeepAliveHandler, urllib2.HTTPSHandler):
AttributeError: 'module' object has no attribute 'HTTPSHandler'
===============================================
 
以上问题是以为没有安装openssl原因,yum不能用。
wget  http://mirrors.163.com/centos/5/os/i386/CentOS/openssl-devel-0.9.8e-20.el5.i386.rpm
wget  http://mirrors.163.com/centos/5/os/i386/CentOS/openssl-0.9.8e-20.el5.i386.rpm
rpm -ivh openssl-0.9.8e-20.el5.i386.rpm 
rpm -ivh openssl-devel-0.9.8e-20.el5.i386.rpm
 
解决

你可能感兴趣的:(yum)