Score:1

Cannot use dpkg or update anything due to kernel

gb flag

since today I have noticed that I cannot install gparted or even check for updates because of unknown error. All I understand is that kernel does not allow to be removed and stops any process that I try to run in the terminal. I have tried force remove. I would also like to mention that my OS does not see grub?

This is the output.

Can someone please explain to me what is happening and how do I fix this issue?

Setting up grub-pc (2.06-2ubuntu12.1) ...

/var/lib/dpkg/info/grub-pc.config: 12: /etc/default/grub: Usage:: not found
dpkg: error processing package grub-pc (--configure):
 installed grub-pc package post-installation script subprocess returned error exit status 127
Setting up linux-image-5.19.0-26-generic (5.19.0-26.27) ...
Setting up linux-image-5.15.0-56-generic (5.15.0-56.62) ...
dpkg: dependency problems prevent configuration of grub-efi-amd64-signed:
 grub-efi-amd64-signed depends on grub-efi-amd64 | grub-pc; however:
  Package grub-efi-amd64 is not installed.
  Package grub-pc is not configured yet.

dpkg: error processing package grub-efi-amd64-signed (--configure):
 dependency problems - leaving unconfigured
Processing triggers for linux-image-5.19.0-26-generic (5.19.0-26.27) ...
/etc/kernel/postinst.d/dkms:
 * dkms: running auto installation service for kernel 5.19.0-26-generic
   ...done.
/etc/kernel/postinst.d/dracut:
dracut: Generating /boot/initrd.img-5.19.0-26-generic
/etc/kernel/postinst.d/zz-update-grub:
Sourcing file `/etc/default/grub'
/usr/sbin/grub-mkconfig: 12: /etc/default/grub: Usage:: not found
run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 127
dpkg: error processing package linux-image-5.19.0-26-generic (--configure):
 installed linux-image-5.19.0-26-generic package post-installation script subprocess returned error exit status 1
Processing triggers for linux-image-5.15.0-56-generic (5.15.0-56.62) ...
/etc/kernel/postinst.d/dkms:
 * dkms: running auto installation service for kernel 5.15.0-56-generic
   ...done.
/etc/kernel/postinst.d/dracut:
dracut: Generating /boot/initrd.img-5.15.0-56-generic
/etc/kernel/postinst.d/zz-update-grub:
Sourcing file `/etc/default/grub'
/usr/sbin/grub-mkconfig: 12: /etc/default/grub: Usage:: not found
run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 127
dpkg: error processing package linux-image-5.15.0-56-generic (--configure):
 installed linux-image-5.15.0-56-generic package post-installation script subprocess returned error exit status 1

**Errors were encountered while processing:
 grub-pc
 grub-efi-amd64-signed
 linux-image-5.19.0-26-generic
 linux-image-5.15.0-56-generic 

This is what I cannot understand at all

Artur Meinild avatar
vn flag
Which version of Ubuntu, and how did you install kernel `5.19.0-26-generic`? Please include in your question.
mc2 avatar
bn flag
mc2
I had similar problem and this answer was helpful: https://askubuntu.com/a/1372049/238032
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.