Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 494884 - sys-boot/grub:2 - grub2-mkconfig does not recognise /boot/initramfs-{version}-gentoo.img generated with sys-kernel/dracut
Summary: sys-boot/grub:2 - grub2-mkconfig does not recognise /boot/initramfs-{version}...
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2013-12-20 17:57 UTC by b1254633
Modified: 2013-12-24 20:19 UTC (History)
2 users (show)

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


Attachments
patch (patch,491 bytes, patch)
2013-12-20 17:58 UTC, b1254633
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description b1254633 2013-12-20 17:57:48 UTC
When you create an initram with dracut, it create a file named in this form: /boot/initramfs-{version}-gentoo.img.

if you update grub.cfg with grub2-mkconfig, it doesn't recognize it.


Reproducible: Always
Comment 1 b1254633 2013-12-20 17:58:25 UTC
Created attachment 365764 [details, diff]
patch
Comment 2 Alexander Tsoy 2013-12-21 21:55:01 UTC
I install kernels with "make install" from the sources dir and I don't have such problem, because "-gentoo" and "-hardened" are parts of the $version variable :P

$ ls /boot/vmlinuz*
/boot/vmlinuz-3.11.7-hardened-r1  /boot/vmlinuz-3.11.9-hardened
/boot/vmlinuz-3.11.8-hardened-r1

$ sudo grep initramfs /boot/grub/grub.cfg 
	initrd	/initramfs-3.11.9-hardened.img
		initrd	/initramfs-3.11.9-hardened.img
		initrd	/initramfs-3.11.9-hardened.img
		initrd	/initramfs-3.11.8-hardened-r1.img
		initrd	/initramfs-3.11.8-hardened-r1.img
		initrd	/initramfs-3.11.7-hardened-r1.img
		initrd	/initramfs-3.11.7-hardened-r1.img
Comment 3 Mike Gilbert gentoo-dev 2013-12-22 19:39:50 UTC
How is your kernel image named?
Comment 4 Mike Gilbert gentoo-dev 2013-12-22 19:43:27 UTC
Also, what kernel sources are you using?
Comment 5 Kolhell 2013-12-24 17:29:07 UTC
I believe my issue is related to this.  When executing
 grub2-mkconfig -0 /boot/grub/grub.cfg
I get outputs of
 Found linux image: /boot/kernel-genkernel-x86_64-3.7.9-gentoo
 Found initrd image: /boot/initramfs-genkernel-x86_64-3.7.9-gentoo
 Found linux image: /boot/kernel-genkernelv2-x86_64-3.7.9-gentoo
but it does not find
 /boot/initramfs-genkernelv2-x86_64-3.7.9-gentoo
I modified
 /etc/genkernel.conf
  KNAME="genkernelv2"
while screwing with genkernel.conf to make sure that I didn't break anything, but grub2-mkconfig doesn't seem to like my naming convention.

I renamed my files
 /boot/kernel-genkernel-x86_64-3.7.9-gentoo
  -> /boot/kernel-genkernel-x86_64-3.7.9-gentoo-safe
 /boot/initramfs-genkernel-x86_64-3.7.9-gentoo
  -> /boot/initramfs-genkernel-x86_64-3.7.9-gentoo-safe
 /boot/kernel-genkernelv2-x86_64-3.7.9-gentoo
  -> /boot/kernel-genkernel-x86_64-3.7.9-gentoo
 /boot/initramfs-genkernelv2-x86_64-3.7.9-gentoo
  -> /boot/initramfs-genkernel-x86_64-3.7.9-gentoo
and everything seems to work fine, but I think it would be nice for grub2-mkconfig to support KNAME="" :P
Comment 6 Mike Gilbert gentoo-dev 2013-12-24 20:19:32 UTC
(In reply to Kolhell from comment #5)

That is bug 492774.