FS#47371 - [gnupg] Gnupg-2.1 does not work well with pacman-key upon fresh install

Attached to Project: Arch Linux
Opened by kozaki (kozaki) - Monday, 14 December 2015, 16:38 GMT
Last edited by Gaetan Bisson (vesath) - Thursday, 24 December 2015, 04:01 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Gaetan Bisson (vesath)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
Upon new installation with archiso 2015-12-01 dual, I tried to add a signed repository and couldn't go further than pacman-key -r <KEY>:

gpg: connecting dirmngr at '/root/.gnupg/S.dirmngr' failed: IPC connect call failed
gpg: keyserver receive failed: No dirmngr
==> ERROR: Remote key not fetched correctly from keyserver.

Continuing from  FS#42798  - [gnupg, pacman] Gnupg-2.1 does not work well with pacman-key
While it's closed I had the same issue on my latest two Arch Linux install. Tip provided in #42798 allowed me to go on each time.

Additionally the information to allow for adding a signed unofficial repo has been removed from the [wiki](https://wiki.archlinux.org/index.php/Pacman/Package_signing#Adding_unofficial_keys)

Steps to reproduce:
1. Install Arch from the latest official ISO
2. Enable a signed unofficial repository in pacman.conf
3. Update pacman
4. Try to add custom key eg: pacman-key -r E6366A92

Additional info:
* package version(s)

- pacman 4.2.1-4
- archlinux-keyring 20151206-1
- gnupg 2.1.10-1

* Miscellaneous

Deleting ~/.gnupg content then add a TU key has same gnupg error message.
This task depends upon

Closed by  Gaetan Bisson (vesath)
Thursday, 24 December 2015, 04:01 GMT
Reason for closing:  Fixed
Additional comments about closing:  gnupg-2.1.10-3 in [testing]
Comment by Doug Newgard (Scimmia) - Monday, 14 December 2015, 16:48 GMT
Is this on the newly installed system or while on the iso?

If we are talking on the newly booted system, does running `dirmngr </dev/null &>/dev/null` fix it? It's currently run on upgrade only.
Comment by Doug Newgard (Scimmia) - Wednesday, 16 December 2015, 05:01 GMT
Ping?
Comment by kozaki (kozaki) - Sunday, 20 December 2015, 05:11 GMT
sorry have a tooth ache you know the wisdom ones
Comment by kozaki (kozaki) - Sunday, 20 December 2015, 11:23 GMT
Hey! Please forgive unwanted delay to reply.

Happened on the *installed* system, twice (I replayed it to check some steps better). Sorry I thought it would be clear from my initial report eg. "Upon new installation with archiso 2015-12-01" and "1. Install Arch from the latest official ISO".

Yes the workarround that worked is the one listed in the former (closed)  FS#42798 . And this bit of information that's needed to allow for adding a signed unofficial repo has been removed from the [wiki](https://wiki.archlinux.org/index.php/Pacman/Package_signing#Adding_unofficial_keys leads nowhere). Adds a layer of unnecessary complexity in case one *needs* to get some stuff from a TUR.
Comment by Gaetan Bisson (vesath) - Monday, 21 December 2015, 04:35 GMT
Please do explain as clearly as possible what changes you'd like to see applied to our current PKGBUILD; thank you for making that extra effort.
Comment by kozaki (kozaki) - Wednesday, 23 December 2015, 19:51 GMT
OK I'm affraid it's away of my abilities but here I try.

In short and as to allow for adding a first signed TUR without the following error

gpg: connecting dirmngr at '/root/.gnupg/S.dirmngr' failed: IPC connect call failed

E.g. to quote Maurizio D'Addona in  FS#42798 : dirmngr still ignores the --homedir option and tries to use /root/.gnupg instead. So you may have to create it yourself on the first launch.

At least display a note on the cause with a link to the workarround, that will also increases the opportunities for the average Arch user to get the relationship between gpg and Pacman. At any case, letting this error as it is with no explanation on why and how to deal with it, even on. the wiki, is not satisfying, is it?
Comment by Doug Newgard (Scimmia) - Wednesday, 23 December 2015, 23:47 GMT
I just did a fresh USB install. I'll make this very simple.

`dirmngr </dev/null &>/dev/null` needs to be run in post_install, not just in post_upgrade.
Comment by Gaetan Bisson (vesath) - Thursday, 24 December 2015, 03:56 GMT
Thanks Doug!

Loading...