Ich erhalte diese Warnung für mehrere Pakete jedes Mal, wenn ich ein Paket installiere oder durchführe apt-get upgrade
. Nicht sicher, was es verursacht; Es ist eine neue Debian-Installation auf meinem OpenVZ-Server und ich habe keine dpkg-Einstellungen geändert.
Hier ist ein Beispiel:
root@debian:~# apt-get install cowsay
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
filters
The following NEW packages will be installed:
cowsay
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 21.9 kB of archives.
After this operation, 91.1 kB of additional disk space will be used.
Get:1 http://ftp.us.debian.org/debian/ unstable/main cowsay all 3.03+dfsg1-4 [21.9 kB]
Fetched 21.9 kB in 0s (70.2 kB/s)
Selecting previously unselected package cowsay.
dpkg: warning: files list file for package 'libssh2-1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libkrb5-3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libwrap0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libcap2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpam-ck-connector:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libc6:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libtalloc2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libselinux1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libp11-kit0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libavahi-client3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libbz2-1.0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpcre3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgpm2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgnutls26:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libavahi-common3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libcroco3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'liblzma5:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpaper1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libsensors4:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libbsd0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libavahi-common-data:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libss2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libblkid1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libslang2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libacl1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libcomerr2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libkrb5support0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'e2fslibs:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'librtmp0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libidn11:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpcap0.8:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libattr1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libdevmapper1.02.1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'odbcinst1debian2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libexpat1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libltdl7:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libkeyutils1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libcups2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libsqlite3-0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libck-connector0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'zlib1g:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libnl1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libfontconfig1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libudev0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libsepol1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libmagic1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libk5crypto3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libunistring0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgpg-error0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libusb-0.1-4:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpam0g:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libpopt0:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgssapi-krb5-2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgeoip1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libcurl3-gnutls:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libtasn1-3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libuuid1:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgcrypt11:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libgdbm3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libdbus-1-3:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libsysfs2:amd64' missing; assuming package has no files currently installed
dpkg: warning: files list file for package 'libfreetype6:amd64' missing; assuming package has no files currently installed
(Reading database ... 21908 files and directories currently installed.)
Unpacking cowsay (from .../cowsay_3.03+dfsg1-4_all.deb) ...
Processing triggers for man-db ...
Setting up cowsay (3.03+dfsg1-4) ...
root@debian:~#
Alles funktioniert gut, aber diese Warnmeldungen sind ziemlich nervig. Weiß jemand, wie ich das beheben kann?
ls -la /var/lib/dpkg/info | grep libssh
:
-rw-r--r-- 1 root root 327 Sep 21 15:51 libssh2-1.list
-rw-r--r-- 1 root root 359 Aug 15 06:06 libssh2-1.md5sums
-rwxr-xr-x 1 root root 135 Aug 15 06:06 libssh2-1.postinst
-rwxr-xr-x 1 root root 132 Aug 15 06:06 libssh2-1.postrm
-rw-r--r-- 1 root root 20 Aug 15 06:06 libssh2-1.shlibs
-rw-r--r-- 1 root root 4377 Aug 15 06:06 libssh2-1.symbols
ls -la /var/lib/dpkg/info | grep libssh
?apt-get update
?Antworten:
Er hat es behoben, die dort erscheinenden Dateien neu zu installieren. Vielleicht möchten Sie also Folgendes ausprobieren:
Kopieren-Einfügen-freundlich in einer Zeile:
Beachten Sie, dass das Ausführen dieses Befehls einige Zeit in Anspruch nimmt , da alle Pakete durchlaufen werden.
In einigen Fällen werden
apt upgrade
die Fehler nicht angezeigt, daher können Sie ein Paket neu installieren (z. B. x), das den Fehler ausgibt, und folgendermaßen ausführen:quelle
-bash: syntax error near unexpected token ``do'
. Nicht gut in Bash; Könnten Sie es bitte reparieren?for
in der vorherigen Zeile verpasst haben ?sudo bash
dann Skript einfügenDie obige Antwort hat bei mir nicht ganz funktioniert. Einige Pakete, nämlich libc6, zeigten diesen Fehler immer noch an.
Ich habe in einem Forum eine Lösung gefunden. Der Fehler ist, dass die neue Version von libc die Liste der Dateien nicht zur Korrektur der Datei zurückgesendet hat. Anstatt es zu
/var/lib/dpkg/info/libc6:amd64.list
wiederholen , wurde es wiederholt/var/lib/dpkg/info/libc6.list
Das Problem kann durch Ausführen behoben werden (passen Sie es an Ihre neueste Version und den neuesten Stand von libc6 an):
Quelle: http://forums.debian.net/viewtopic.php?f=5&t=93201
Viel Glück für alle, die dies in Zukunft lesen und für brauchbar halten.
quelle
dpkg-deb -c /var/cache/apt/archives/libc6_2.13-38_amd64.deb
Einträge mit symbolischen Links vorhanden sind, z. B.dpkg-deb -c /var/cache/apt/archives/mc_3%3a4.8.13-3_amd64.deb | grep mc.csh
returniert./usr/share/mc/bin/mc.csh -> ../../../lib/mc/mc.csh
Versuchen Sie, dieses Skript zu speichern:
Führen Sie es dann mit aus
Dies erforderte ein wenig zusätzliche Arbeit und einige andere Befehle
zusammen mit dem Entfernen und Neuinstallieren einiger spezifischer Pakete.
Dies kostet einiges an Zeit und Mühe, wird aber trotzdem ein
apt-get
paar Fehler zeigen.quelle
Nicht genügend Repräsentanten, um einen Kommentar abzugeben: @exic / @mark, ich habe festgestellt, dass ein Backtick am Anfang des Paketnamens und anschließend eine Anführungszeichen verwendet wird. Daher muss eine andere Interpunktion überprüft werden. Ich bin mir nicht sicher, ob dies verwandt war. Meine Lösung:
quelle
Kopieren Sie die Fehlermeldung beispielsweise in eine Datei
111.txt
. Führen Sie dann den Befehl ausquelle
Bei allen anderen Antworten wird davon ausgegangen, dass Sie die Pakete erneut installieren möchten. In meinem Fall wollte ich das nicht. Ich hatte
locate
versucht, alle Spuren von ihnen zu entfernen, einschließlich der zugehörigen Apt-Dateilisten.Der erste Schritt besteht darin, sicherzustellen, dass die Pakete mit dem Paketmanager entfernt werden:
Dann hat apt einen Befehl, den Sie ausführen können, um es zu bereinigen. Dies beseitigt die Warnung, während die Pakete deinstalliert bleiben:
Quelle bei Ask Ubuntu: Dateilistendatei für Paket fehlt
quelle
Ich benutze das Deepin Linux Betriebssystem und habe die obigen Befehle so geändert, dass sie funktionieren. Ich benutze chinesische Sprache.
for package in $(sed "s/.*\ \(.*\)\ .*/\1/" error.txt); do apt-get install -y --reinstall "$package"; done
wenn Sie Englisch sprechenfor package in $(sed "s/.*'\(.*\)'.*/\1/" error.txt); do apt-get install -y --reinstall "$package"; done
quelle
Ich habe nie einen der oben genannten Befehle zum Laufen gebracht, aber dies funktionierte schließlich für mich, nachdem ich die Fehlermeldung in der Datei error.txt ausgegeben hatte
Hoffe es hilft jemand anderem.
quelle