Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 917567 - sys-apps/systemd(-utils): kernel-install does not raise a non-zero exit status upon plugin failure
Summary: sys-apps/systemd(-utils): kernel-install does not raise a non-zero exit statu...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo systemd Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-18 15:14 UTC by Kobboi
Modified: 2023-11-30 04:05 UTC (History)
2 users (show)

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


Attachments
larger tail of emerge process (log,10.88 KB, text/plain)
2023-11-18 15:17 UTC, Kobboi
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kobboi 2023-11-18 15:14:54 UTC
About to execute /usr/lib/kernel/install.d/90-loaderentry.install add 6.5.11-gentoo-dist /efi/dedd82f833a632a43a4a7efb63a84bf0/6.5.11-gentoo-dist /usr/src/linux-6.5.11-gentoo-dist/arch/x86/boot/bzImage
Successfully forked off '(direxec)' as PID 45395.
Installing /efi/dedd82f833a632a43a4a7efb63a84bf0/6.5.11-gentoo-dist/initrd
/usr/bin/install: error writing '/efi/dedd82f833a632a43a4a7efb63a84bf0/6.5.11-gentoo-dist/initrd': No space left on device
Error: could not copy '/tmp/kernel-install.staging.rgiGBz/initrd' to '/efi/dedd82f833a632a43a4a7efb63a84bf0/6.5.11-gentoo-dist/initrd'.
/usr/lib/kernel/install.d/90-loaderentry.install failed with exit status 1.
/usr/lib/kernel/install.d/90-loaderentry.install failed with exit status 1.
(sd-executor) failed with exit status 1.                                                                                                                 [ ok ]
>>> sys-kernel/gentoo-kernel-bin-6.5.11 merged.


Reproducible: Always
Comment 1 Kobboi 2023-11-18 15:17:50 UTC
Created attachment 875148 [details]
larger tail of emerge process
Comment 2 Kobboi 2023-11-18 15:32:48 UTC
In dist-kernel-utils.eclass, installkernel "${version}" "${image}" "${map}" returns 0 when this occurs
Comment 3 Andrew Ammerlaan gentoo-dev 2023-11-18 15:34:24 UTC
(In reply to Kobboi from comment #2)
> In dist-kernel-utils.eclass, installkernel "${version}" "${image}" "${map}"
> returns 0 when this occurs

What if you add || exit 1 to the kernel-install command in /sbin/installkernel?
Comment 4 Florian Schmaus gentoo-dev 2023-11-18 16:26:47 UTC
Which systemd version is this?
Comment 5 Andrew Ammerlaan gentoo-dev 2023-11-18 19:24:30 UTC
I can reproduce the problem by adding exit 1 into any of the kernel-install plugins and running 'kernel-install add 6.6.1-gentoo-dist /usr/src/linux/arch/x86/boot/bzImage'. The exit status is always 0. This is not related to installkernel-systemd, or the dist kernel, but appears to be an issue with kernel-install instead.
Comment 6 Andrew Ammerlaan gentoo-dev 2023-11-18 19:38:55 UTC
Reported upstream: https://github.com/systemd/systemd/issues/30087
Comment 7 Kobboi 2023-11-19 02:18:48 UTC
(In reply to Andrew Ammerlaan from comment #3)
> (In reply to Kobboi from comment #2)
> > In dist-kernel-utils.eclass, installkernel "${version}" "${image}" "${map}"
> > returns 0 when this occurs
> 
> What if you add || exit 1 to the kernel-install command in
> /sbin/installkernel?

Sorry, saw this too late. Thanks for your investigation and taking this upstream.
Comment 8 Andrew Ammerlaan gentoo-dev 2023-11-20 13:35:23 UTC
This is now fixed upstream, and should be in the next release.
Comment 9 Larry the Git Cow gentoo-dev 2023-11-30 04:05:15 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8896792af466b7f25719c7492a75ea3fef3e65da

commit 8896792af466b7f25719c7492a75ea3fef3e65da
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-11-30 04:04:39 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-11-30 04:04:39 +0000

    sys-apps/systemd-utils: add 254.7
    
    Closes: https://bugs.gentoo.org/917567
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-apps/systemd-utils/Manifest                   |   1 +
 sys-apps/systemd-utils/systemd-utils-254.7.ebuild | 575 ++++++++++++++++++++++
 2 files changed, 576 insertions(+)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dcfe3135995f684b2469d4a4ff12d8d968a1407c

commit dcfe3135995f684b2469d4a4ff12d8d968a1407c
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-11-30 04:02:01 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-11-30 04:02:01 +0000

    sys-apps/systemd: add 254.7
    
    Closes: https://bugs.gentoo.org/917567
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-apps/systemd/Manifest             |   1 +
 sys-apps/systemd/systemd-254.7.ebuild | 525 ++++++++++++++++++++++++++++++++++
 2 files changed, 526 insertions(+)