Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 881767 - emerge --sync fails with "gpg: Fatal: getentropy is not supported: Function not implemented"
Summary: emerge --sync fails with "gpg: Fatal: getentropy is not supported: Function n...
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-18 07:46 UTC by Vincent Le Ligeour
Modified: 2022-11-19 09:48 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Le Ligeour 2022-11-18 07:46:07 UTC
Hello,

While trying to sync my portage tree I get the following error:
  gpg: Fatal: getentropy is not supported: Function not implemented

The error seems quite new and my guess is that a recent bump in glibc is causing it in relation to my very old kernel (3.10).

I haven't yet being able to bisect the issue (host is very slow to compile), I am currently bumping my kernel version to see if it fixes the issue.

If this glibc commit entered a stable gentoo glibc recently it might be a culprit:
https://github.com/bminor/glibc/commit/658b5848a827876cc8a5e518749f78429a9970d7

Reproducible: Always

Steps to Reproduce:
1. launch emerge --sync
2. error is generated
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-11-18 07:47:12 UTC
If running an old kernel, please try USE=-getentropy on dev-libs/libgcrypt.

```
commit 8bacde9ab38c268737a14ffa2c5c239c406d23d8
Author: Mike Gilbert <floppym@gentoo.org>
Date:   Fri Nov 4 11:55:40 2022 -0400

    dev-libs/libgcrypt: add kernel version check for getentropy

    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

commit 8c19036cac71bf2b45459cc7d66b5985e2956c69
Author: Mike Gilbert <floppym@gentoo.org>
Date:   Fri Nov 4 11:34:10 2022 -0400

    dev-libs/libgcrypt: add 'getentropy' USE flag

    This allows for explicit control of the --enable-random configure
    option.

    Signed-off-by: Mike Gilbert <floppym@gentoo.org>
```
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-11-18 07:49:01 UTC
(I am wondering if we should change it to USE=old-kernel like Qt has, because at least then it's something somewhat obvious to set if you're on something ancient.)
Comment 3 Vincent Le Ligeour 2022-11-19 09:47:32 UTC
Hello,

Indeed the timestamp of my Manifest is exactly during the time the tree was broken (not possible to sync the tree anymore after libgcrypt update):
  TIMESTAMP 2022-11-01T23:09:46Z

By downloading the latest version of the ebuild from git (https://gitweb.gentoo.org/repo/gentoo.git/plain/dev-libs/libgcrypt/libgcrypt-1.10.1-r2.ebuild?id=8bacde9ab38c268737a14ffa2c5c239c406d23d8) and rebuilding the 
ebuild's digest, compilation is fine:
- error by default (telling that getentropy is not supported for old kernels),
- compiles correctly with USE=-getentropy,
- emerge --sync then works correctly.