Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Kernel & Hardware
  • Search

6.18.9 - Failed to create binpkg of e2fsprogs [SOLVED]

Kernel not recognizing your hardware? Problems with power management or PCMCIA? What hardware is compatible with Gentoo? See here. (Only for kernels supported by Gentoo.)
Post Reply
Advanced search
8 posts • Page 1 of 1
Author
Message
MorgothSauron
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 89
Joined: Thu Sep 24, 2020 4:43 pm

6.18.9 - Failed to create binpkg of e2fsprogs [SOLVED]

  • Quote

Post by MorgothSauron » Wed Feb 11, 2026 6:00 pm

Hi,
I'm encountering a weird error while trying to compile kernel 6.18.9. It fails with the following error:

Code: Select all

* ERROR: Command 'nice -n10 make -j8 V=1' failed!
* ERROR: create_initramfs(): append_data(): append_e2fsprogs(): populate_binpkg(): gkbuild(): Failed to create binpkg of e2fsprogs-1.47.0!
genkernel output:

Code: Select all

# ~/bin/kernel-tools.py build -d
WARNING: Will unset existing variable 'TMPDIR' to avoid clashing with genkernel config ...
* Gentoo Linux Genkernel; Version 4.3.17
* Using genkernel configuration from '/etc/genkernel.conf' ...
* Running with options: --kernel-config=/usr/src/linux/.config_custom --makeopts=-j8 --microcode=intel --bootloader=grub2 --no-virtio --no-hyperv --no-nfs --no-lvm --no-mdadm --no-iscsi --no-dmraid --no-zfs --luks --btrfs --e2fsprogs --oldconfig --nconfig all

* Working with Linux kernel 6.18.9-gentoo-x86_64 for x86_64
* Using kernel config file '/usr/src/linux-6.18.9-gentoo/.config_custom' ...
* 
* Note: The version above is subject to change (depends on config and status of kernel sources).

* kernel: >> Initializing ...
*         >> --no-clean is set; Skipping 'make clean' ...
*         >> --no-mrproper is set; Skipping 'make mrproper' ...
*         >> Will ignore kernel config from '/usr/src/linux-6.18.9-gentoo/.config_custom'
*            in favor of already existing but different kernel config
*            found in '/usr/src/linux/.config' ...
*         >> Running 'make oldconfig' ...
*         >> Invoking nconfig ...
*         >> Kernel config was not modified!
*         >> Re-running 'make oldconfig' due to changed kernel options ...
*         >> Compiling 6.18.9-gentoo-x86_64 bzImage ...
*         >> Compiling 6.18.9-gentoo-x86_64 modules ...
*         >> Installing 6.18.9-gentoo-x86_64 modules (and stripping) ...
*         >> Generating module dependency data ...
*         >> Compiling out-of-tree module(s) ...
*         >> Saving config of successful build to '/etc/kernels/kernel-config-6.18.9-gentoo-x86_64' ...

* initramfs: >> Initializing ...
*         >> Appending devices cpio data ...
*         >> Appending base_layout cpio data ...
*         >> Appending util-linux cpio data ...
*         >> Appending eudev cpio data ...
*         >> Appending devicemanager cpio data ...
*         >> Appending auxiliary cpio data ...
*         >> Appending busybox cpio data ...
*         >> Appending btrfs cpio data ...
*         >> Appending e2fsprogs cpio data ...
* ERROR: Command 'nice -n10 make -j8 V=1' failed!
* ERROR: create_initramfs(): append_data(): append_e2fsprogs(): populate_binpkg(): gkbuild(): Failed to create binpkg of e2fsprogs-1.47.0!
* Please consult '/var/log/genkernel.log' for more information and any
* errors that were reported above.
* 
* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* '/var/log/genkernel.log' so that your issue can be dealt with effectively.
* 
* Please do *not* report kernel compilation failures as genkernel bugs!
* 
Traceback (most recent call last):
  File "/home/root/bin/kernel-tools.py", line 197, in <module>
    sys.exit(main())
             ~~~~^^
  File "/home/root/bin/kernel-tools.py", line 178, in main
    genkernel(mode = build_mode)
    ~~~~~~~~~^^^^^^^^^^^^^^^^^^^
  File "/home/root/bin/kernel-tools.py", line 122, in genkernel
    raise RuntimeError("An error occurred while building the kernel")
RuntimeError: An error occurred while building the kernel
#
The last few lines of /var/log/genkernel.log:

Code: Select all

x86_64-pc-linux-gnu-gcc -I. -I../../lib -I../../lib  -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include  -Os -pipe -fomit-frame-pointer -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include -pthread  -DHAVE_CONFIG_H  -c unix_io.c -o unix_io.o
x86_64-pc-linux-gnu-gcc -I. -I../../lib -I../../lib  -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include  -Os -pipe -fomit-frame-pointer -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include -pthread  -DHAVE_CONFIG_H  -c sparse_io.c -o sparse_io.o
tdb.c:113:13: error: 'bool' cannot be defined via 'typedef'
  113 | typedef int bool;
      |             ^~~~
tdb.c:113:13: note: 'bool' is a keyword with '-std=c23' onwards
tdb.c:113:1: warning: useless type name in empty declaration
  113 | typedef int bool;
      | ^~~~~~~
x86_64-pc-linux-gnu-gcc -I. -I../../lib -I../../lib  -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include  -Os -pipe -fomit-frame-pointer -I/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/buildroot/usr/include -pthread  -DHAVE_CONFIG_H  -c unlink.c -o unlink.o
make[2]: *** [Makefile:619: tdb.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/e2fsprogs-1.47.0/lib/ext2fs'
make[1]: *** [Makefile:458: all-libs-recursive] Error 1
make[1]: Leaving directory '/var/tmp/genkernel/gk_xDtZjYUu/e2fsprogs/e2fsprogs-1.47.0'
make: *** [Makefile:372: all] Error 2
* ERROR: Command 'nice -n10 make -j8 V=1' failed!

* ERROR: create_initramfs(): append_data(): append_e2fsprogs(): populate_binpkg(): gkbuild(): Failed to create binpkg of e2fsprogs-1.47.0!
* Please consult '/var/log/genkernel.log' for more information and any
* errors that were reported above.
* 
* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* '/var/log/genkernel.log' so that your issue can be dealt with effectively.
* 
* Please do *not* report kernel compilation failures as genkernel bugs!
* 

* mount: >> Boot partition state on '/boot' was not changed; Skipping restore boot partition state ...
>>> Ended on: 2026-02-11 18:43:13 (after 0 days 0 hours 22 minutes 52 seconds)
gcc version:

Code: Select all

# gcc --version
gcc (Gentoo 15.2.1_p20251122 p3) 15.2.1 20251122
Copyright (C) 2025 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.

# eselect gcc list
  [1] x86_64-pc-linux-gnu-15 *
# 


I didn't have any problem compiling other kernels in the 6.18 series until this point.

I didn't install any new package recently. I'm just updating the system every other week.

I do remember glibc updates recently, but I'm not sure if it is related.

Any idea what could cause the compilation to fail for this specific kernel.
Last edited by MorgothSauron on Thu Feb 12, 2026 6:36 pm, edited 1 time in total.
Top
Hu
Administrator
Administrator
Posts: 24385
Joined: Tue Mar 06, 2007 5:38 am

  • Quote

Post by Hu » Wed Feb 11, 2026 7:29 pm

Why are you trying to use genkernel? As I understand it, users are encouraged to move off it.

Why are you trying to build e2fsprogs-1.47.0? That version is not even in the main tree anymore. Your specific error is a gcc porting issue. Build e2fsprogs with an age-appropriate C standard version, use a compiler from that age, or build an e2fsprogs that is new enough to have been fixed.
Top
flexibeast
l33t
l33t
Posts: 679
Joined: Mon Apr 04, 2022 4:15 am
Location: Naarm/Melbourne, Australia
Contact:
Contact flexibeast
Website

  • Quote

Post by flexibeast » Wed Feb 11, 2026 10:25 pm

Hu wrote:Why are you trying to use genkernel? As I understand it, users are encouraged to move off it.
Yes, the "genkernel" page on the wiki has a warning:
genkernel is unmaintained; documentation presented here may be incomplete and may not reflect the current state of Gentoo tooling. Users encountering issues with genkernel will be asked to use another tool. Please see the Distribution kernel section in the Handbook for a supported alternative.
Here's the "Distribution kernel" section in the Handbook.
https://wiki.gentoo.org/wiki/User:Flexibeast
My most recent wiki contributions
Top
MorgothSauron
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 89
Joined: Thu Sep 24, 2020 4:43 pm

  • Quote

Post by MorgothSauron » Thu Feb 12, 2026 4:52 pm

I've been using genkernel for so long that it never crossed my mind it was discontinued/unmaintained.

I have no problem to move to a different method to compile the kernel. I'd prefer to continue to use the gentoo-sources package.

I guess compiling the kernel is more or less a matter of running the right make commands in /usr/src/linux.

However, I need an initramfs (luks + root on btrfs). What are the options to generate an initramfs ? dracut ?

At this stage I'm asking for clues to start working in the right direction to do things in a more modern way.
Top
pietinger
Moderator
Moderator
Posts: 6620
Joined: Tue Oct 17, 2006 5:11 pm
Location: Bavaria

  • Quote

Post by pietinger » Thu Feb 12, 2026 5:04 pm

MorgothSauron wrote:[...] [1] I'd prefer to continue to use the gentoo-sources package.

[2] I guess compiling the kernel is more or less a matter of running the right make commands in /usr/src/linux.

[3] However, I need an initramfs (luks + root on btrfs). What are the options to generate an initramfs ? dracut ?
1) Great, this gives you some advantages. 8)
2) Yes and no. The first configuration of your manually configured kernel is hard. Later it is easy with doing just an "make oldconfig".
3) If you compile all necessary kernel modules for accessing the root partition as built-in, then ugrd can create a very small initramfs. Also the developer of ugrd is very active in our forum ... ;-)

Maybe start here:
https://wiki.gentoo.org/wiki/User:Pieti ... figuration
https://wiki.gentoo.org/wiki/User:Pietinger --> https://wiki.gentoo.org/wiki/User:Pieti ... _at_Gentoo
Top
MorgothSauron
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 89
Joined: Thu Sep 24, 2020 4:43 pm

  • Quote

Post by MorgothSauron » Thu Feb 12, 2026 6:36 pm

pietinger wrote:
MorgothSauron wrote:[...] [1] I'd prefer to continue to use the gentoo-sources package.

[2] I guess compiling the kernel is more or less a matter of running the right make commands in /usr/src/linux.

[3] However, I need an initramfs (luks + root on btrfs). What are the options to generate an initramfs ? dracut ?
1) Great, this gives you some advantages. 8)
2) Yes and no. The first configuration of your manually configured kernel is hard. Later it is easy with doing just an "make oldconfig".
3) If you compile all necessary kernel modules for accessing the root partition as built-in, then ugrd can create a very small initramfs. Also the developer of ugrd is very active in our forum ... ;-)

Maybe start here:
https://wiki.gentoo.org/wiki/User:Pieti ... figuration
I'm not an expert, but I had to configure the kernel on some occasions to add drivers or to add extra modules not included by default.

I did some quick test and it seems to work properly with the following steps.

Code: Select all

# dump the running configuration
zcat /proc/config.gz > /usr/src/linux/.config

# oldconfig
make -C /usr/src/linux oldconfig

# compile
make -C /usr/src/linux -j$(nproc)

# install
make -C /usr/src/linux install
make -C /usr/src/linux modules_install

# run dracut to generate a new initramfs for the new kernel. not specifying the version will use the running kernel version
dracut --host-only --kver 6.18.9-gentoo-x86_64 --force

# update grub configuration
grub-mkconfig -o /boot/grub/grub.cfg

# reboot to test new configuration
I'm sure there's a better way to do it, but I wanted to compile and boot 6.18.9. I suppose something like installkernel could be the solution to avoid these manual steps.

There was no problem booting the new kernel.

The only thing I noticed is that the LUKS passphrase prompt is not easy to notice ... it is hidden among other output lines. Its there, but not the last line of output. At first I though the system wouldn't boot. I just typed the passphrase and the system booted normally.

I will have a look at ugrd for sure.

I will mark this post as solved. Not using genkernel allowed me to compile and install the 6.18.9 kernel with a working initramfs using dracut

Edit: I added the --kver option to the dracut command to make sure it uses the newly installed kernel instead of the running one. Here I specify 6.18.9 because it's the kernel I was installing at that time. I use the name of the kernel as it is listed under /lib/modules. I successfully applied this procedure today with 6.19.0 :D
Last edited by MorgothSauron on Fri Feb 13, 2026 6:49 pm, edited 1 time in total.
Top
pietinger
Moderator
Moderator
Posts: 6620
Joined: Tue Oct 17, 2006 5:11 pm
Location: Bavaria

  • Quote

Post by pietinger » Thu Feb 12, 2026 11:35 pm

MorgothSauron wrote:[1] I'm not an expert, but I had to configure the kernel on some occasions to add drivers or to add extra modules not included by default.

[2] I did some quick test and it seems to work properly with the following steps.

Code: Select all

# dump the running configuration
zcat /proc/config.gz > /usr/src/linux/.config

# oldconfig
make -C /usr/src/linux oldconfig
[...]
[3] I'm sure there's a better way to do it, but I wanted to compile and boot 6.18.9. I suppose something like installkernel could be the solution to avoid these manual steps.

[4] There was no problem booting the new kernel.
1) It is not necessary to be a kernel expert ... I am also not a kernel expert ... ;-)

2) Perfect. This tells me you already had a working config and could use it. You did all well.

3) No. installkernel will not help you with these steps. installkernel will only install a hook, so when you copy your kernel to /boot (with "make install") it will be renamed to the correct name ... which is important for grub-mkconfig later.
(see my chapter: https://wiki.gentoo.org/wiki/User:Pieti ... el_package )

4. Great ... but ... I dont know which kernel version you had before. When you had used genkernel before then there will be surely some kernel options not enabled. For example we got (with 6.16) CONFIG_X86_NATIVE_CPU ...
(see also here: https://wiki.gentoo.org/wiki/User:Pieti ... s_for_6.16 )
... which I can strongly recommend ... so what I want to suggest is: Take your current .config and verify with "make menuconfig" all the (new) options of 6.18

and yes, from my "main" article about

https://wiki.gentoo.org/wiki/User:Pieti ... figuration

there is a link to:

https://wiki.gentoo.org/wiki/User:Pieti ... rsion_6.18

Maybe have a look and optimize (and harden) your kernel.
https://wiki.gentoo.org/wiki/User:Pietinger --> https://wiki.gentoo.org/wiki/User:Pieti ... _at_Gentoo
Top
zen_desu
Guru
Guru
Posts: 501
Joined: Fri Oct 25, 2024 3:14 pm
Location: your area

  • Quote

Post by zen_desu » Fri Feb 13, 2026 12:12 am

MorgothSauron wrote: There was no problem booting the new kernel.

The only thing I noticed is that the LUKS passphrase prompt is not easy to notice ... it is hidden among other output lines. Its there, but not the last line of output. At first I though the system wouldn't boot. I just typed the passphrase and the system booted normally.

I will have a look at ugrd for sure.

I will mark this post as solved. Not using genkernel allowed me to compile and install the 6.18.9 kernel with a working initramfs using dracut
If you use installkernel, you can set USE flags for your preferred initramfs/bootloader, and running "make install" in the sources dir will automatically regenerate/configure that stuff. It's not required but helps you keep things working reliably. When regenerating an initramfs in particular, you have to be sure to provide the kernel version of the kernel you're building otherwise the kernel which is running will be targeted for initramfs builds. installkernel passes this info for you.

If dracut just worked for you, there isn't much of a reason to use ugrd unless you're just interested in smaller images and more "validation" for the generated image. ugrd is basically only designed to make "hostonly" images but they are very minimal and will only include utils to boot.

If you're interested in a custom initramfs, the build dir ugrd makes is designed to be explored/edited by the user, and the whole "init" is just POSIX shell.

In your case, adding the "quiet" cmdline arg to the kernel command line should make it easier to see the prompt, but you may enjoy the typical logging from ugrd as it's designed to look somewhat like openrc and shouldn't have much "noise"
µgRD dev
Wiki writer
Top
Post Reply

8 posts • Page 1 of 1

Return to “Kernel & Hardware”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic