Invalid and corrupt database

Good day
Every time I try to update my software or install something I get an error. “Invalid or corrupt database”.I’m new to Manjaro. Please help

recent:///40ad5841b17a69984f10008361e927ce

Hi,

You have provided very little information so I don’t know what the exact error is. Have you tried refreshing the database?

pamac update --force-refresh 

Hi.See error
error: sublime-text: key “F57D4F59BD3DF454” is unknown
:: Import PGP key F57D4F59BD3DF454? [Y/n] y
error: key “F57D4F59BD3DF454” could not be looked up remotely
:: Synchronizing package databases…
core 169.5 KiB 5.01 MiB/s 00:00 [######################] 100%
extra 1915.0 KiB 3.28 MiB/s 00:01 [######################] 100%
community 6.8 MiB 3.19 MiB/s 00:02 [######################] 100%
multilib 175.5 KiB 5.19 MiB/s 00:00 [######################] 100%
sublime-text 1841.0 B 0.00 B/s 00:00 [######################] 100%
sublime-text.sig 543.0 B 0.00 B/s 00:00 [######################] 100%
error: sublime-text: key “F57D4F59BD3DF454” is unknown
:: Import PGP key F57D4F59BD3DF454? [Y/n] n
error: failed to update sublime-text (invalid or corrupted database (PGP signature))
error: failed to synchronize all databases

How did you install sublime-text?

If it’s directly from the developer they have instruction on importing the key:

curl -O https://download.sublimetext.com/sublimehq-pub.gpg && sudo pacman-key --add sublimehq-pub.gpg && sudo pacman-key --lsign-key 8A8F901A && rm sublimehq-pub.gpg

See Linux Package Manager Repositories – Sublime Text Documentation

I don’t remember how I installed it but the problem started when I deleted it.Cause i didn’t use it

Sublime pgp-key has changed a while before. So you have to renew it in the way like @NGr has tell. :wink:

==> Updating trust database…
gpg: no need for a trustdb check
==> ERROR: There is no secret key available to sign with.
==> Use ‘pacman-key --init’ to generate a default secret key.

Tried pacman- key --init
==> ERROR: pacman-key needs to be run as root for this operation.

Still getting errors

sudo rm -r /etc/pacman.d/gnupg
sudo pacman-key --init
sudo pacman-key --populate archlinux manjaro
sudo pacman-key --refresh-keys

gpg: refreshing 148 keys from hkps://hkps.pool.sks-keyservers.net
gpg: keyserver refresh failed: No name
==> ERROR: A specified local key could not be updated from a keyserver.

You could try deleting the specific key. I haven’t has this problem before so can’t say if it will work.

sudo pacman-key -d F57D4F59BD3DF454

==> ERROR: The key identified by F57D4F59BD3DF454 could not be found locally

It looks like the commands from ishaan removed the key. Have you tried refreshing the database since?

EDIT: If there is still errors, try following the new instructions under ’ Errors about Keys’ here: Pacman troubleshooting - Manjaro

sudo pacman-key --refresh-keys
gpg: refreshing 148 keys from hkps://hkps.pool.sks-keyservers.net
gpg: keyserver refresh failed: No name
==> ERROR: A specified local key could not be updated from a keyserver.

gpg --recv-keys
bash: syntax error near unexpected token `newline’

Thank you guys for your help,I can finally update my software now. :wink:

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