gpg: keyserver receive failed: No dirmngr

  • While trying to receive keys in my Debian Stretch server, I get this error:

    sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
    Executing: /tmp/apt-key-gpghome.4B7hWtn7Rm/gpg.1.sh --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
    gpg: failed to start the dirmngr '/usr/bin/dirmngr': No such file or directory
    gpg: connecting dirmngr at '/tmp/apt-key-gpghome.4B7hWtn7Rm/S.dirmngr' failed: No such file or directory
    gpg: keyserver receive failed: No dirmngr
    
  • Installing the package dirmngr fixed the error.

    [email protected]:~$ sudo apt-get install dirmngr
    

    Retrying :

    [email protected]:~$ sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
    Executing: /tmp/apt-key-gpghome.haKuPppywi/gpg.1.sh --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
    gpg: key A6A19B38D3D831EF: public key "Xamarin Public Jenkins (auto-signing) <[email protected]>" imported
    gpg: Total number processed: 1
    gpg:               imported: 1
    

    Had same problem on Debian 9.4. Installing dirmngr fixed it.

    I got the same error of the OP, but I already have latest gpg installed.

    installing `gpg` fixed it for me on a Debian 9.3. `dirmngr` was already installed.

    Same issue on Raspbian 9.8 stretch. Installing dirmngr resolved it. Thanks.

License under CC-BY-SA with attribution


Content dated before 6/26/2020 9:53 AM