(Reading database ... 234944 files and directories currently installed.)
Removing linux-image-5.8.0-55-generic (5.8.0-55.62~20.04.1) ...
/etc/kernel/postrm.d/initramfs-tools:
update-initramfs: Deleting /boot/initrd.img-5.8.0-55-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 ...
Script `/boot/grub/grub.cfg.new' contains no commands and will do nothing
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub/grub.cfg.new file attached.
run-parts: /etc/kernel/postrm.d/zz-update-grub exited with return code 1
dpkg: error processing package linux-image-5.8.0-55-generic (--remove):
installed linux-image-5.8.0-55-generic package post-removal script subprocess r
eturned error exit status 1
dpkg: too many errors, stopping
Errors were encountered while processing:
linux-image-5.8.0-55-generic
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.2 LTS
Release: 20.04
Codename: focal
sudo apt install devscripts
on each package in the output to identify packages with incompatible with 20.04 versions. Syntax:rmadison linux-generic
– karel Sep 18 '21 at 11:24sudo apt install package1 package2
– karel Sep 18 '21 at 11:35apt search package1
to find the correct version. That will get you a working system. – karel Sep 18 '21 at 11:47