Good to Know Database

CentOS 5: YUM bricht mit Fehlermeldungen ab


Sollten Sie beim Updaten eines CentOS 5 Systems oder beim Installieren von einzelnen Paketen die folgenden oder ähnliche Fehlermeldungen angezeigt bekommen, hilft Ihnen in der Regel das Löschen des lokalen Caches weiter.

[root@centos5 ~]# yum update
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package audit-libs.x86_64 0:1.7.7-6.el5_3.3 set to be updated
---> Package audit-libs.i386 0:1.7.7-6.el5_3.3 set to be updated
---> Package pango.x86_64 0:1.14.9-5.el5.centos set to be updated
---> Package file.x86_64 0:4.17-15.el5_3.1 set to be updated
---> Package audit.x86_64 0:1.7.7-6.el5_3.3 set to be updated
---> Package sos.noarch 0:1.7-9.16.el5_3.5 set to be updated
---> Package audit-libs-python.x86_64 0:1.7.7-6.el5_3.3 set to be updated
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 229, in user_main
    errcode = main(args)
  File "/usr/share/yum-cli/yummain.py", line 145, in main
    (result, resultmsgs) = base.buildTransaction()
  File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 647, in buildTransaction
    (rescode, restring) = self.resolveDeps()
  File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 704, in resolveDeps
    for po, dep in self._checkFileRequires():
  File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 939, in _checkFileRequires
    if not self.tsInfo.getOldProvides(filename) and not self.tsInfo.getNewProvides(filename):
  File "/usr/lib/python2.4/site-packages/yum/transactioninfo.py", line 414, in getNewProvides
    for pkg, hits in self.pkgSack.getProvides(name, flag, version).iteritems():
  File "/usr/lib/python2.4/site-packages/yum/packageSack.py", line 300, in getProvides
    return self._computeAggregateDictResult("getProvides", name, flags, version)
  File "/usr/lib/python2.4/site-packages/yum/packageSack.py", line 470, in _computeAggregateDictResult
    sackResult = apply(method, args)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 861, in getProvides
    return self._search("provides", name, flags, version)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 43, in newFunc
    return func(*args, **kwargs)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 837, in _search
    for pkg in self.searchFiles(name, strict=True):
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 43, in newFunc
    return func(*args, **kwargs)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 586, in searchFiles
    self._sql_pkgKey2po(rep, cur, pkgs)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 470, in _sql_pkgKey2po
    pkg = self._packageByKey(repo, ob['pkgKey'])
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 413, in _packageByKey
    po = self.pc(repo, cur.fetchone())
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 68, in __init__
    self._read_db_obj(db_obj)
  File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 94, in _read_db_obj
    setattr(self, item, _share_data(db_obj[item]))
TypeError: unsubscriptable object

Mit dem folgenden Befehl löschen Sie alle zwischengespeicherten Pakete, alle Header-Dateien welche YUM zur Abhängigkeitsüberprüfung verwendet, alle Metadaten über verfügbare Pakete und den SQLite Cache der Metadaten. Beim nächsten Aufruf von YUM werden die benötigten Daten erneut heruntergeladen und der SQLite Cache wird neu erstellt.

[root@centos5 ~]# yum clean all
Loaded plugins: fastestmirror
Cleaning up Everything
Cleaning up list of fastest mirrors

Nachdem Sie alle zwischengespeicherten Daten gelöscht haben, versuchen Sie erneut ein Update durchzuführen oder ein Paket zu installieren.

[root@centos5 ~]# yum update
Loaded plugins: fastestmirror
Determining fastest mirrors
fedora-epel                                              | 2.1 kB     00:00
primary.sqlite.bz2                                       | 3.0 MB     00:00
base                                                     | 1.1 kB     00:00
primary.xml.gz                                           | 1.1 MB     00:00
base                                                           3272/3272
updates                                                  |  951 B     00:00
primary.xml.gz                                           | 151 kB     00:00
updates                                                        281/281
extras                                                   | 1.1 kB     00:00
primary.xml.gz                                           |  98 kB     00:00
extras                                                         266/266
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package sos.noarch 0:1.7-9.16.el5_3.5 set to be updated
---> Package audit-libs-python.x86_64 0:1.7.7-6.el5_3.3 set to be updated
---> Package pango.x86_64 0:1.14.9-5.el5.centos set to be updated
---> Package audit-libs.i386 0:1.7.7-6.el5_3.3 set to be updated
---> Package audit-libs.x86_64 0:1.7.7-6.el5_3.3 set to be updated
---> Package file.x86_64 0:4.17-15.el5_3.1 set to be updated
---> Package audit.x86_64 0:1.7.7-6.el5_3.3 set to be updated
filelists.sqlite.bz2                                     | 4.7 MB     00:00
filelists.xml.gz                                         | 1.0 MB     00:00
filelists.xml.gz                                         | 3.3 MB     00:00
filelists.xml.gz                                         | 148 kB     00:00
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package                Arch        Version                  Repository    Size
================================================================================
Updating:
 audit                  x86_64      1.7.7-6.el5_3.3          updates      369 k
 audit-libs             i386        1.7.7-6.el5_3.3          updates       77 k
 audit-libs             x86_64      1.7.7-6.el5_3.3          updates       81 k
 audit-libs-python      x86_64      1.7.7-6.el5_3.3          updates       79 k
 file                   x86_64      4.17-15.el5_3.1          updates      318 k
 pango                  x86_64      1.14.9-5.el5.centos      updates      338 k
 sos                    noarch      1.7-9.16.el5_3.5         updates      116 k

Transaction Summary
================================================================================
Install      0 Package(s)
Update       7 Package(s)
Remove       0 Package(s)

Total download size: 1.3 M
Is this ok [y/N]:


Dieser Eintrag wurde am 10.05.2009 erstellt.

Direkter Link zu dieser Seite: http://www.gtkdb.de/index_33_612.html

[ Zur Startseite ]   [ Zur Kategorie ]


Valid XHTML 1.0 Transitional Valid CSS Valid Atom 1.0

© 2004-2018 by Georg Kainzbauer