"error: GPGME error: No data" when trying to do anything in pacman

I am getting this error when trying to update (along with some other things):

[manjaro ~]# pacman -Syu
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
:: Synchronizing package databases...
 core                  169.4 KiB   184 KiB/s 00:01 [----------------------] 100%
 extra                1882.8 KiB  2.72 MiB/s 00:01 [----------------------] 100%
 community               6.6 MiB  3.99 MiB/s 00:02 [----------------------] 100%
 multilib              176.5 KiB  1124 KiB/s 00:00 [----------------------] 100%
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: failed to synchronize all databases (invalid or corrupted database (PGP signature))

I’ve followed the steps at "error: GPGME error: No data" when I'm trying to update but to no avail.

The error us usually caused by a mirror returning a 404 document.

You can verify using

file /var/lib/pacman/sync/core.db

If the result is html then you need to run paceman-mirrors to reset your mirror list.

sudo pacman-mirrors -c all

Then retry the terminal update command

Running file /var/lib/pacman/sync/core.db returns:

/var/lib/pacman/sync/core.db: gzip compressed data, last modified: Thu Aug 19 14:11:38 2021, from Unix, original size modulo 2^32 1156096

Running sudo pacman-mirrors -c all right now

Got this output from sudo pacman-mirrors -c all:

sudo pacman -Syy                                    
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
:: Synchronizing package databases...
 core                  169.4 KiB   179 KiB/s 00:01 [----------------------] 100%
 extra                1882.8 KiB  1681 KiB/s 00:01 [----------------------] 100%
 community               6.6 MiB  4.71 MiB/s 00:01 [----------------------] 100%
 multilib              176.5 KiB  1124 KiB/s 00:00 [----------------------] 100%
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: failed to synchronize all databases (invalid or corrupted database (PGP signature))

Try doing sudo pacman-mirrors -f 5 then sudo pacman -Syyu

Here’s the output of each command:

sudo pacman-mirrors -f 5
[sudo] password for yiannis: 
::INFO Downloading mirrors from Manjaro
::INFO => Mirror pool: https://repo.manjaro.org/mirrors.json
::INFO => Mirror status: http://repo.manjaro.org/status.json
::INFO Using default mirror file
::INFO Querying mirrors - This may take some time
  3.980 Brazil         : https://manjaro.c3sl.ufpr.br/
  1.016 Poland         : https://repo.skni.umcs.pl/manjaro/
  0.814 Poland         : http://repo.skni.umcs.pl/manjaro/
  0.697 Ukraine        : http://mirrors.colocall.net/manjaro/
  ..... Ukraine        : ftp://mirrors.colocall.net/manjaro/

::ERROR ftp error: error_perm('550 Failed to change directory.')

  2.259 United_States  : https://repo.ialab.dsu.edu/manjaro/
  1.656 United_States  : http://repo.ialab.dsu.edu/manjaro/
  1.290 Hungary        : https://quantum-mirror.hu/mirrors/pub/manjaro/
  0.890 Hungary        : http://quantum-mirror.hu/mirrors/pub/manjaro/
::INFO Writing mirror list
::Poland          : https://repo.skni.umcs.pl/manjaro/testing
::Hungary         : https://quantum-mirror.hu/mirrors/pub/manjaro/testing
::United_States   : https://repo.ialab.dsu.edu/manjaro/testing
::Brazil          : https://manjaro.c3sl.ufpr.br/testing
::INFO Mirror list generated and saved to: /etc/pacman.d/mirrorlist
sudo pacman -Syyu
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
:: Synchronizing package databases...
 core                  169.4 KiB   115 KiB/s 00:01 [----------------------] 100%
 extra                1882.8 KiB   445 KiB/s 00:04 [----------------------] 100%
 community               6.6 MiB   637 KiB/s 00:11 [----------------------] 100%
 multilib              176.5 KiB   494 KiB/s 00:00 [----------------------] 100%
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: failed to synchronize all databases (invalid or corrupted database (PGP signature))

It appears the file is a regular database - so the error is puzzling.

I have had these errors some time back - and my final solution was the above - but I only asked you to test the core.db - you can test all the db files using

file /var/lib/pacman/sync/*.db

You can remove the files from the sync folder then retry the update

sudo rm -f /var/lib/pacman/sync/*
file /var/lib/pacman/sync/*.db

returns:

/var/lib/pacman/sync/community.db: gzip compressed data, last modified: Thu Aug 19 14:12:46 2021, from Unix, original size modulo 2^32 41745408
/var/lib/pacman/sync/core.db:      gzip compressed data, last modified: Thu Aug 19 14:11:38 2021, from Unix, original size modulo 2^32 1156096
/var/lib/pacman/sync/extra.db:     gzip compressed data, last modified: Thu Aug 19 14:11:57 2021, from Unix, original size modulo 2^32 13974528
/var/lib/pacman/sync/multilib.db:  gzip compressed data, last modified: Thu Aug 19 14:11:40 2021, from Unix, original size modulo 2^32 1229312

Still getting this error after /var/lib/pacman/sync/*.db

sudo pacman -Syu
:: Synchronizing package databases...
 core                  169.4 KiB   144 KiB/s 00:01 [----------------------] 100%
 extra                1882.8 KiB   371 KiB/s 00:05 [----------------------] 100%
 community               6.6 MiB   274 KiB/s 00:25 [----------------------] 100%
 multilib              176.5 KiB   230 KiB/s 00:01 [----------------------] 100%
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: GPGME error: No data
error: failed to synchronize all databases (invalid or corrupted database (PGP signature))

Found the fix here: https://stackoverflow.com/a/67850084/9660537

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