E: /usr/bin/dpkg returned an error code (1)

Hello ,i have this error any time when I upgrade or when I want to install something !!
It happen after I used these commands:

dpkg --print-architecture
dpkg --print-foreign-architectures
sudo dpkg --add-architecture i386
And when I use udo dpkg --configure -a … this what it shows:
└──╼ $sudo dpkg --configure -a
[sudo] password for rsoy:
Setting up initramfs-tools (0.139) …
update-initramfs: deferring update (trigger activated)
Processing triggers for initramfs-tools (0.139) …
update-initramfs: Generating /boot/initrd.img-5.9.0-2parrot1-amd64
W: Possible missing firmware /lib/firmware/i915/rkl_dmc_ver2_01.bin for module i915
pigz: abort: write error on (No space left on device)
E: mkinitramfs failure cpio 141 pigz 28
update-initramfs: failed for /boot/initrd.img-5.9.0-2parrot1-amd64 with 1.
dpkg: error processing package initramfs-tools (–configure):
installed initramfs-tools package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:

Looks like your /boot partition is full so the new kernel can’t be built.

What is the free space looking like on your install?

df -h

You will probably need to run the following:

dpkg -l linux-{image,headers}-"[0-9]*" | awk '/^ii/{ print $2}' | grep -v -e `uname -r | cut -f1,2 -d"-"` | grep -e '[0-9]' | xargs sudo apt -y purge


sudo apt autoremove

Linux is putting each kernel (initrd.img-*) in /boot. Either your /boot partition is too small, or you have a number of old kernels in there.

> ┌─[rsoy@parrot]─[~]
> └──╼ $df -h
> Filesystem      Size  Used Avail Use% Mounted on
> udev            3.9G     0  3.9G   0% /dev
> tmpfs           792M  1.5M  790M   1% /run
> /dev/sda6       237G   30G  207G  13% /
> tmpfs           3.9G   16M  3.9G   1% /dev/shm
> tmpfs           5.0M  4.0K  5.0M   1% /run/lock
> tmpfs           4.0M     0  4.0M   0% /sys/fs/cgroup
> /dev/sda5       464M  405M   31M  93% /boot
> tmpfs           792M   88K  792M   1% /run/user/1000
> /dev/sda1       225G  194G   32G  87% /media/rsoy/Nouveau nom

That’s the issue. You only have 31M left on the boot partition. You will need to remove all additional kernels except the last one, then sudo parrot-upgrade to install the latest kernel.

The easiest way to do this is use Synaptic to search for name = linux-image and do a Mark for Complete Removal, then Apply. Leave the last one alone though.

It worked, thanks… but it still shows

W: Possible missing firmware /lib/firmware/i915/rkl_dmc_ver2_01.bin for module i915

No problem. I was getting that message on one of my devices running Parrot too.

1 Like

Okay then, thanks so much for help!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.