0

when I ever I want to make most of the things in terminal I faced this problem ,even when I try to run sudo apt upgrade , it also appear I try to reinstall it by using sudo apt install --reinstall linux-headers-5.4.0-56 linux-headers-5.4.0-56-generic and it appear also

SH EB
  • 1
  • 2

1 Answers1

1

This package was removed from the repositories a few weeks ago. You can resolve the issue by doing this:

  1. Open Terminal (if it's not already open)

  2. Run this command:

    sudo apt remove linux-modules-5.4.0-56-generic
    

From here you can clean apt a little bit with:

$ sudo apt autoremove && sudo apt clean
$ sudo apt update

This should resolve the problem

  • when running :sudo apt remove linux-modules-5.4.0-56-generic Reading package lists... Done Building dependency tree Reading state information... Done E: The package linux-headers-5.4.0-56 needs to be reinstalled, but an archive for it can't be found. – SH EB Feb 02 '21 at 08:44
  • 1
    then try to remove it with dpkg. `sudo dpkg -P linux-modules-5.4.0-56-generic` – nobody Feb 02 '21 at 08:57
  • If that doesn't work, [this is an excellent walk-through of how to remove packages when things go sour](https://askubuntu.com/a/968759/1091774). Scroll down to the "How to manage broken packages" section and start from the first step. Hopefully you don't need to get all the way through to number five. –  Feb 02 '21 at 09:01