Problems with pacman

can anyone explain me whats up with this and how to solve this

sudo pacman -S Libreoffice

[sudo] password for PC:

error: failed to init transaction (unable to lock database)
error: could not lock database: File exists
if you’re sure a package manager is not already
running, you can remove /var/lib/pacman/db.lck

Hi @FakharHaider,

I think if you’re sure there’s no other instance of pacman running, you can do as the message say and remove db.lck:

sudo rm /var/lib/pacman/db.lck

Also, I’d suggest not using pacman any more, and rather use pamac as that is developed by Manjaro devs for Manjaro. So your pacman comand would become:

pamac install libreoffice-fresh

Hope this helps!

1 Like

is there anyadvantages in using pamac over pacman ?

I think you meant
pamac install libreoffice-fresh

1 Like

Pamac will also build AUR packages for you and if there are updates build them to.

1 Like

It is built by Manjaro (devs) for Manjaro. So yes, I’d say there is.