感谢支持
我们一直在努力

Fedora yum出错的解决方案

重新安装了Fedora 9,用于更新软件的时候,发生类似如下的错误。


sudo yum install MySQL
Loaded plugins: refresh-packagekit
YumRepo Warning: not using ftp, http[s], or file for repos, skipping –
YumRepo Warning: not using ftp, http[s], or file for repos, skipping –
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 241, in user_main
errcode = main(args)
File “/usr/share/yum-cli/yummain.py”, line 116, in main
result, resultmsgs = base.doCommands()
File “/usr/share/yum-cli/cli.py”, line 307, in doCommands
self._getTs()
File “/usr/lib/Python2.5/site-packages/yum/depsolve.py”, line 98, in _getTs
self._getTsInfo()
File “/usr/lib/python2.5/site-packages/yum/depsolve.py”, line 104, in _getTsInfo
self._tsInfo.setDatabases(self.rpmdb, self.pkgSack)
File “/usr/lib/python2.5/site-packages/yum/__init__.py”, line 576, in
pkgSack = property(fget=lambda self: self._getSacks(),
File “/usr/lib/python2.5/site-packages/yum/__init__.py”, line 419, in _getSacks
self.repos.populateSack(which=repos)
File “/usr/lib/python2.5/site-packages/yum/repos.py”, line 245, in populateSack
sack.populate(repo, mdtype, callback, cacheonly)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 149, in populate
if self._check_db_version(repo, mydbtype):
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 203, in _check_db_version
return repo._check_db_version(mdtype)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 928, in _check_db_version
repoXML = self.repoXML
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 1086, in
repoXML = property(fget=lambda self: self._getRepoXML(),
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 1078, in _getRepoXML
self._loadRepoXML(text=self)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 1068, in _loadRepoXML
return self._groupLoadRepoXML(text, [“primary”])
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 1052, in _groupLoadRepoXML
if self._commonLoadRepoXML(text):
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 904, in _commonLoadRepoXML
result = self._getFileRepoXML(local, text)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 772, in _getFileRepoXML
cache=self.http_caching == ‘all’)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 643, in _getFile
result = self.grab.urlgrab(relative, local,
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 463, in
grab = property(lambda self: self._getgrab())
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 458, in _getgrab
self._setupGrab()
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 447, in _setupGrab
self._grab = mgclass(self._grabfunc, self.urls,
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 548, in
urls = property(fget=lambda self: self._geturls(),
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 545, in _geturls
self._baseurlSetup()
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 514, in _baseurlSetup
self.mirrorurls = self._replace_and_check_url(mirrorurls)
File “/usr/lib/python2.5/site-packages/yum/yumRepo.py”, line 536, in _replace_and_check_url
print ‘YumRepo Warning: not using ftp, http[s], or file for repos, skipping – %s’ % (url)
File “/usr/lib/python2.5/codecs.py”, line 303, in write
data, consumed = self.encode(object, self.errors)
UnicodeDecodeError: ‘ascii’ codec can’t decode byte 0xbb in position 78: ordinal not in range(128)


通过GOOGLE查了一下,发现有人是这么解决的


yum remove yum-fastmirror


我也试了一下,没有解决。


我的解决方法是:yum clean all


解决者:Netstu

赞(0) 打赏
转载请注明出处:服务器评测 » Fedora yum出错的解决方案
分享到: 更多 (0)

听说打赏我的人,都进福布斯排行榜啦!

支付宝扫一扫打赏

微信扫一扫打赏