1

I'm trying to install packages with apt-get and every time I try to install anything I get:

acanada@ubuntu:~$ sudo apt-get install python3-pip
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 linux-headers-4.4.0-45-generic : Depends: linux-headers-4.4.0-45 but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

So, I do the apt-get -f install command and get:

acanada@ubuntu:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  gnome-video-effects guile-2.0-libs libgc1c2 libwhoopsie-preferences0
  linux-headers-4.4.0-31 linux-headers-4.4.0-31-generic
  linux-image-4.4.0-31-generic linux-image-extra-4.4.0-31-generic
  whoopsie-preferences
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  linux-headers-4.4.0-45
The following NEW packages will be installed:
  linux-headers-4.4.0-45
0 upgraded, 1 newly installed, 0 to remove and 146 not upgraded.
41 not fully installed or removed.
Need to get 0 B/9,988 kB of archives.
After this operation, 70.4 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 270809 files and directories currently installed.)
Preparing to unpack .../linux-headers-4.4.0-45_4.4.0-45.66_all.deb ...
Unpacking linux-headers-4.4.0-45 (4.4.0-45.66) ...
dpkg-deb (subprocess): decompressing archive member: lzma error: compressed data is corrupt
dpkg-deb: error: subprocess <decompress> returned error exit status 2
dpkg: error processing archive /var/cache/apt/archives/linux-headers-4.4.0-45_4.4.0-45.66_all.deb (--unpack):
 subprocess dpkg-deb --fsys-tarfile returned error exit status 2
No apport report written because the error message indicates an issue on the local system
         Errors were encountered while processing:
 /var/cache/apt/archives/linux-headers-4.4.0-45_4.4.0-45.66_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Is there any way to fix this? I can't install any packages because it comes up with the same error.

user1972601
  • 11
  • 1
  • 2
  • Download the header deb file manually from here [http://packages.ubuntu.com/xenial/linux-headers-4.4.0-45](http://packages.ubuntu.com/xenial/linux-headers-4.4.0-45), open a terminal where you downloaded the file and `sudo dpkg -i *.deb` – GrannySez Oct 27 '16 at 04:26
  • 2
    Delete `/var/cache/apt/archives/linux-headers-4.4.0-45_4.4.0-45.66_all.deb` and run the installation again so that it re-downloads the file correctly. – muru Oct 27 '16 at 04:31
  • ran sudo dpkg -i *.deb after downloading and extracting files, received an error of acanada@ubuntu:~/Downloads/linux-4.4$ sudo dpkg -i *.deb [sudo] password for acanada: dpkg: error processing archive *.deb (--install): cannot access archive: No such file or directory Errors were encountered while processing: *.deb' – user1972601 Oct 27 '16 at 04:40
  • @user1972601 Extracting files? – muru Oct 27 '16 at 04:46
  • @muru yes, I downloaded [linux_4.4.0.orig.tar.gz] and extracted those files – user1972601 Oct 27 '16 at 04:55
  • See [Upgrade Firefox fails. lzma error: compressed data is corrupt](http://askubuntu.com/questions/519867/upgrade-firefox-fails-lzma-error-compressed-data-is-corrupt) - different .deb, same error – steeldriver Oct 27 '16 at 12:20

0 Answers0