Fresh install (Ubuntu 16.04 LTS) I'm unable to update or install anything via
apt. I can run
apt update fine but if I follow that with either
apt upgrade or
apt dist-upgrade it always (I've tried doing so after countless reboots, as well as from recovery mode) results in:
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.
If I run that it always does the following and just hangs indefinitely:
Setting up grub-efi-amd64 (2.02~beta2-36ubuntu3.12) ... Installing for x86_64-efi platform. Installation finished. No error reported. Generating grub configuration file ... Found linux image: /boot/vmlinuz-4.10.0-35-generic Found initrd image: /boot/initrd.img-4.10.0-35-generic Found linux image: /boot/vmlinuz-4.10.0-28-generic Found initrd image: /boot/initrd.img-4.10.0-28-generic
uname -r shows it's running
4.10.0-35-generic so I'd be fine removing
4.10.0-28-generic since that's where it always hangs but I'm unable to purge it because that just results in
apt purge hanging when it gets to
Found initrd image: /boot/initrd.img-4.10.0-28-generic.
I've tried every possible ordering of the following without success
sudo dpkg --configure -a sudo apt install -f sudo apt clean sudo apt update sudo apt upgrade|dist-upgrade|full-upgrade
This is a fresh install so I'm not worried about any "nuclear" options that would result in data loss (i.e. I have no data to lose). I have tried using boot-repair but it never completed (it said it may take a few minutes but I left it running for hours).
I realize the similarities between this question and both E: dpkg was interrupted... run 'sudo dpkg --configure -a' and dpkg --configure -a hangs when found initrd image but none of the answers have helped.