Similar to how-to-get-dpkg-working-again
my daily apt-get has had this error, completely failing to update anything:
root@chopin~ Wed Feb 01,16:23:56# (5473) apt-get -y install Reading package lists...
Done
Building dependency tree... 50%
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
python-twisted-core
Suggested packages:
python-qt3 python-profiler
The following packages will be upgraded:
python-twisted-core
1 upgraded, 0 newly installed, 0 to remove and 82 not upgraded. 1 not fully installed or removed.
Need to get 0 B/1,129 kB of archives.
After this operation, 8,360 kB of additional disk space will be used. (Reading database ...
dpkg: warning: files list file for package `python-twisted-core' missing, assuming package has no files currently installed.
(Reading database... 277181 files and directories currently installed.)
Preparing to replace python-twisted-core 10.2.0-1 (using .../python-twisted-core_10.2.0-1_all.deb) ...
Unpacking replacement python-twisted-core ...
dpkg: ../../src/archives.c:968: tarobject:
Assertion `r == stab.st_size' failed.
localepurge: Disk space freed in /usr/share/locale: 0 KiB
localepurge: Disk space freed in /usr/share/man: 0 KiB
localepurge: Disk space freed in /usr/share/gnome/help: 0 KiB
localepurge: Disk space freed in /usr/share/omf: 0 KiB
localepurge: Disk space freed in /usr/share/doc/kde/HTML: 0 KiB
Total disk space freed by localepurge: 0 KiB
N: Ignoring file 'apt-build' in directory '/etc/apt/sources.list.d/' as it has no filename extension
E: Sub-process /usr/bin/dpkg exited unexpectedly
Have experienced this horrific show-stopper across three servers on and off for two years, using Ubuntu 10.04, 10.10, and 11.04 32bit systems.
All manner of troubleshooting with launchpad.net has only gone in circles. I do not use ntfs but ext4. apt-get purge
fails, dpkg --configure -a
exits instantly with no output, blaming python-twisted-core
seemed to go nowhere.
I may be on to something. The next wave of auto-updates break it again though.
root@chopin/var/lib/dpkg/info Thu Feb 02,15:03:39# (5743) **dpkg --remove --force-remove-reinstreq python-twisted-core**
dpkg: warning: overriding problem because --force enabled:
Package is in a very bad inconsistent state - you should
reinstall it before attempting a removal.
(Reading database ...
dpkg: warning: files list file for package `python-twisted-core' missing, assuming package has no files currently installed.
(Reading database ... 277171 files and directories currently installed.)
Removing python-twisted-core ...
root@chopin/var/lib/dpkg/info Thu Feb 02,15:03:54# (5744) **apt-get install geany debsums -y**
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
geany-plugins
The following NEW packages will be installed:
debsums geany
0 upgraded, 2 newly installed, 0 to remove and 86 not upgraded.
Need to get 0 B/2,756 kB of archives.
After this operation, 8,016 kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously deselected package debsums.
(Reading database ... 277175 files and directories currently installed.)
Unpacking debsums (from .../debsums_2.0.48+nmu3_all.deb) ...
Selecting previously deselected package geany.
Unpacking geany (from .../geany_0.20-0ubuntu2_i386.deb) ...
Processing triggers for man-db ...
Processing triggers for desktop-file-utils ...
Processing triggers for python-gmenu ...
Rebuilding /usr/share/applications/desktop.en_US.utf8.cache...
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for hicolor-icon-theme ...
Processing triggers for doc-base ...
Processing 1 added doc-base file(s)...
Registering documents with scrollkeeper...
Processing triggers for menu ...
Processing triggers for python-support ...
Setting up debsums (2.0.48+nmu3) ...
Creating config file /etc/apt/apt.conf.d/90debsums with new version
Setting up geany (0.20-0ubuntu2) ...
Processing triggers for menu ...
localepurge: Disk space freed in /usr/share/locale: 2660 KiB
localepurge: Disk space freed in /usr/share/man: 72 KiB
localepurge: Disk space freed in /usr/share/gnome/help: 0 KiB
localepurge: Disk space freed in /usr/share/omf: 0 KiB
localepurge: Disk space freed in /usr/share/doc/kde/HTML: 0 KiB
Total disk space freed by localepurge: 2732 KiB
N: Ignoring file 'apt-build' in directory '/etc/apt/sources.list.d/' as it has no filename extension
root@chopin/var/lib/dpkg/info Thu Feb 02,15:04:55# (5744) **time debsums_init &**
Did you try doing
apt-get clean
and thenapt-get install
again?The error message suggests there's a problem uncompressing the package:
I'd also do a full disk and memory check to be sure, but apt-get clean can hopefully help.