Errors during update; metadata, bad message, structure needs cleaning

Hi, i’m getting this error.
Updating trough add/remove app

Kernel: 5.15.7-1-MANJARO
DE: Plasma 5.23.4

Preparing...
Synchronizing package databases...
Resolving dependencies...
Checking inter-conflicts...
Warning: could not fully load metadata for package elfutils-0.186-1
Failed to prepare transaction:
invalid or corrupted package

EDIT:
Reinstalled Manjaro, fixed :slight_smile:

sudo rm /var/cache/pacman/pkg/elfutils-0.186-1*

Then sort mirrors and update again:

sudo pacman-mirrors -f && sudo pacman -Syyu
1 Like
sudo rm /var/cache/pacman/pkg/elfutils-0.186-1*
zsh: no matches found: /var/cache/pacman/pkg/elfutils-0.186-1*
sudo rm /var/cache/pacman/pkg/elfutils-0.186-1
rm: cannot remove '/var/cache/pacman/pkg/elfutils-0.186-1': No such file or directory

and for mirrors and update is this error:

:: Starting full system upgrade...
error: could not open file /var/lib/pacman/local/elfutils-0.186-1/desc: Bad message
resolving dependencies...
error: could not open file /var/lib/pacman/local/e2fsprogs-1.46.4-1/desc: Bad message
error: could not open file /var/lib/pacman/local/ecryptfs-utils-111-5/desc: Structure needs cleaning
error: could not open file /var/lib/pacman/local/efibootmgr-17-2/desc: Bad message
error: could not open file /var/lib/pacman/local/efivar-37-4/desc: Bad message
looking for conflicting packages...
warning: could not fully load metadata for package elfutils-0.186-1
error: failed to prepare transaction (invalid or corrupted package)

When i try to install any app i get that same error “invalid or corrupted package”.

Is there a fix for this?