Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 704354 - genkernel 4.0.1-8-gc3afe9b-git: ldconfig fails
Summary: genkernel 4.0.1-8-gc3afe9b-git: ldconfig fails
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: genkernel (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Genkernel Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-12-31 07:34 UTC by Robin Johnson
Modified: 2019-12-31 17:25 UTC (History)
1 user (show)

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 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2019-12-31 07:34:00 UTC
*         >> Pre-generating initramfs' /etc/ld.so.cache ...
* ERROR: Failed to pre-generate '/var/tmp/portage-tmpfs/portage/sys-kernel/gentoo-infra-kernel-sources-4.19.91/temp/tmp/gk_IPmkDEr9/initramfs-final/etc/ld.so.cache'!
* Please consult '/var/tmp/portage-tmpfs/portage/sys-kernel/gentoo-infra-kernel-sources-4.19.91/temp/genkernel.log' for more information and any
* errors that were reported above.


Editing it to drop the 2> and print out the command first, with -v for verbose:
SANDBOX_ON=0 ldconfig -v -f /etc/ld.so.conf -r /var/tmp/portage-tmpfs/portage/sys-kernel/gentoo-infra-kernel-sources-4.19.91/temp/tmp/gk_IPmkDEr9/initramfs-final
ldconfig: need absolute file name for configuration file when using -r

# ldconfig --version
ldconfig (Gentoo 2.30-r2 p3) 2.30
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Andreas Jaeger.
# qfile -v $(which ldconfig)
sys-libs/glibc-2.30-r2: /sbin/ldconfig


Not clear why it thinks that it's not an absolute path. It looks quite absolute to me.
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2019-12-31 10:07:48 UTC
This is entirely due to running ldconfig as a non-root user. Seems it was broken somewhere in the GK4 transition.
Comment 2 Thomas Deutschmann (RETIRED) gentoo-dev 2019-12-31 14:34:50 UTC
(In reply to Robin Johnson from comment #0)
> Editing it to drop the 2> and print out the command first, with -v for
> verbose:
> SANDBOX_ON=0 ldconfig -v -f /etc/ld.so.conf -r
> /var/tmp/portage-tmpfs/portage/sys-kernel/gentoo-infra-kernel-sources-4.19.
> 91/temp/tmp/gk_IPmkDEr9/initramfs-final
> ldconfig: need absolute file name for configuration file when using -r
> 
> # ldconfig --version
> ldconfig (Gentoo 2.30-r2 p3) 2.30
> Copyright (C) 2019 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
> Written by Andreas Jaeger.
> # qfile -v $(which ldconfig)
> sys-libs/glibc-2.30-r2: /sbin/ldconfig
> 
> 
> Not clear why it thinks that it's not an absolute path. It looks quite
> absolute to me.

See comment https://gitweb.gentoo.org/proj/genkernel.git/tree/gen_initramfs.sh?h=v4.0.1#n1812 (bug 431038).

I am currently wondering why you hit this at all. I know that several people are using genkernel-4 in ebuilds without problems.
Comment 3 Larry the Git Cow gentoo-dev 2019-12-31 17:25:38 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=cb705cfd0dc3800a085f5ccba4681b73b1fe2287

commit cb705cfd0dc3800a085f5ccba4681b73b1fe2287
Author:     Thomas Deutschmann <whissi@gentoo.org>
AuthorDate: 2019-12-31 17:18:19 +0000
Commit:     Thomas Deutschmann <whissi@gentoo.org>
CommitDate: 2019-12-31 17:18:19 +0000

    gen_initramfs.sh: create_initramfs(): Make ldconfig failure non-fatal
    
    Having up-to-date /etc/ld.so.cache in initramfs is nice to have but not
    critical and ldconfig is known to fail when running under sandbox.
    
    Closes: https://bugs.gentoo.org/704354
    Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>

 gen_initramfs.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)