ArchLabs Linux

Repeated “unable to lock database” or “failed to synchronize any databases” errors

Hi All,

I attempted to update yesterday and Arch returned the message,
unable to lock database and exited.
I had to manually remove the /var/lib/pacman/db.lck and then re-issue sudo pacman -Sy.
This happened again today.
I have never faced this issue before. is there a workaround to fix this so that I will not have to remove the /var/lib/pacman/db.lck file all the time manually in future?
Can you please advise?

/Arindam Basu

Try this, see what it does;

sudo pacman -Scc

sudo pacman -Syyu

Hi @arinbasu, maybe look at this post:

And look at @Dobbie03 post.

hi,for update use:
pacman -Syu
pacman -Sy

1 Like

This. Thank you @ector. Sound advice.