Announcement

Collapse
No announcement yet.

Old kernel doesn't uninstall after upgrade

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Old kernel doesn't uninstall after upgrade

    Updated to 22.04 from 21.10. Seemed to go well except for the following error at the end. The package refuses to uninstall and gets the following error:

    Code:
    Reading package lists... Done
    Building dependency tree... Done
    Reading state information... Done
    The following packages will be REMOVED:
     linux-image-5.13.0-28-generic
    0 to upgrade, 0 to newly install, 1 to remove and 0 not to upgrade.
    1 not fully installed or removed.
    After this operation, 10.3 MB disk space will be freed.
    Do you want to continue? [Y/n]  
    (Reading database ... 283445 files and directories currently installed.)
    Removing linux-image-5.13.0-28-generic (5.13.0-28.31) ...
    /etc/kernel/postrm.d/initramfs-tools:
    update-initramfs: Deleting /boot/initrd.img-5.13.0-28-generic
    /etc/kernel/postrm.d/zz-update-grub:
    Sourcing file `/etc/default/grub'
    Sourcing file `/etc/default/grub.d/init-select.cfg'
    Generating grub configuration file ...
    /etc/grub.d/bin/grubcfg_proxy: error while loading shared libraries: libcrypto.so.1.1: cannot open shared object file: No such file or directory
    run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 127
    dpkg: error processing package linux-image-5.13.0-28-generic (--remove):
    installed linux-image-5.13.0-28-generic package post-removal script subprocess returned error exit status 1
    dpkg: too many errors, stopping
    Errors were encountered while processing:
    linux-image-5.13.0-28-generic
    Processing was halted because there were too many errors.
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    The system boots and seems to operate as expected, except that the package manager indicates that updates are available when there are none.

    Any ideas how to fix this?
    Last edited by Snowhog; Apr 26, 2022, 06:16 AM.

    #2
    The error you're showing above doesn't really relate to your complaint - not being able to remove a kernel image doesn't equal unfinished upgrades.

    Lets start by running the following commands:

    sudo apt update
    sudo apt list --upgradable


    and post the output.

    This will insure you have the current package list and will show what, if any, packages need upgrading.

    Please Read Me

    Comment


      #3
      Yes, it does! The install failed at the last step where it deletes packages that are redundant.

      I found the answer here: https://askubuntu.com/questions/1116...file-o#1136130

      I had to copy the missing file into the correct directory, and then the old kernel could be deleted. Also, the issue prevented me from adding packages.

      Comment

      Working...
      X