GRUB2 Menu missing

I've just followed the recently updated guide: Run a Distribution-Supplied Kernel on a KVM Linode

~~[https://www.linode.com/docs/tools-reference/custom-kernels-distros/run-a-distribution-supplied-kernel-with-kvm" target="_blank">](https://www.linode.com/docs/tools-refer … l-with-kvm">https://www.linode.com/docs/tools-reference/custom-kernels-distros/run-a-distribution-supplied-kernel-with-kvm](

and it works, but I can't see the grub menu any more.

It pauses for the right amount of time, then boots correctly,

I just see a blank screen with a cursor in the top left corner.

Steps taken:
* Deploy image (Fedora 22)

  • Follow guide (above) exactly

  • Reboot

Have I done something wrong?

Cheers,

Rich / FlatCap

[Edit: Just tested a Debian 7 install (just in case), same problem]

4 Replies

I encountered exactly the same problem while experimenting with KVM, but I think I've discovered at least a partial solution, at least for Debian 8. The guide includes a note near the end that you may see (and safely ignore) "error: file `/boot/grub/i386-pc/all_video.mod' not found" and indeed I did see that error, but I think it's directly related to the cause of the invisible grub menu.

While installing grub2, it asks where to install onto a disk, and (per the guide) I elected to continue without installing to any drive. However, this causes the installation process to stop before generating image and various module files, including the missing module noted above. To generate these files, without actually installing grub to the MBR, you can run the following (as root):

# grub-install --grub-setup=/bin/true /dev/null

This forces grub to bypass the MBR installation step normally done by grub-setup. You still need to specify a target, even though it won't actually write anything, so /dev/null seems to work. After this command, you should be able to find the missing module file (and many more) within your /boot/grub/i386-pc.

Upon reboot, you should be able to see the grub menu again, although not quite perfectly. Grub and the Lish screen session don't seem to agree on the screen geometry at first, but once you start to move around within the menu, it becomes visible as normal and seems to be fully functional.

However, there's now a different error that appears, at least for Debian 8. Just before the boot process begins, whether selected manually or by default after the timeout, I see: "error: symbol `grubvideofbgetregion' not found." As far as I can tell, this can be safely ignored, as after a few seconds (despite saying "Press any key to continue…") the system will continue to boot on its own without any interaction, so it's still suitable for unattended reboots. I suspect the error is due to some sort of version skew between whatever grub version Linode uses to load our grub.cfg file and the grub we're installing, so it may not even be an issue for all distributions.

Hi theBrain, thanks for you input.

I've just spent a while trying again – deleting lines from grub.cfg until it broke.

The first problem, for Fedora users, is that it puts everything in /boot/grub2 so I recommend:

ln -s grub2 /boot/grub

I followed your instructions to generate the grub modules.

But, I've managed to sidestep the need by using the config:

GRUB_GFXPAYLOAD_LINUX="text"
GRUB_TERMINAL="serial"

These cause the following lines to be put into grub.cfg

serial
terminal_input serial
terminal_output serial

NOW, I see the menu, but as you point out, it's a bit wonky if your terminal isn't 80x24 characters.

Note, I've also removed the serial line speeds. They don't seem to be necessary.

My full /etc/default/grub looks like:

GRUB_CMDLINE_LINUX="console=ttyS0"
GRUB_DEFAULT=0
GRUB_DISABLE_RECOVERY="true"
GRUB_DISABLE_SUBMENU=true
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_GFXPAYLOAD_LINUX="text"
GRUB_SERIAL_COMMAND="serial"
GRUB_TERMINAL="serial"
GRUB_TIMEOUT=5

Below is the stripped down, but WORKING, output of grub-mkconfig

serial
terminal_input serial
terminal_output serial
set timeout_style=menu
set timeout=5

menuentry 'Fedora 22' --class fedora --class gnu-linux --class gnu --class os --unrestricted 'gnulinux-4.0.7-300.fc22.x86_64-advanced-e7051d37-c6f7-450f-bf21-eec3a735838a' {
    set gfxpayload=text
    insmod gzio
    insmod ext2
    set root='hd0'
    search --no-floppy --fs-uuid --set=root 5558db20-252a-4342-94f3-86886e17afe0
    linux16 /boot/vmlinuz-4.0.7-300.fc22.x86_64 root=UUID=5558db20-252a-4342-94f3-86886e17afe0 ro console=ttyS0 
    initrd16 /boot/initramfs-4.0.7-300.fc22.x86_64.img
}

I tried, but failed, to get the default Debian 7 deployment to work.

It seems to have a different version of grub2.

My machine works, so I'm happy.

Rich / FlatCap

same problem on centos 7.

is there someone who get rid of this error?

just for reference, this is the correct config for CentOS 7 and grub2.

GRUB_TIMEOUT=10
GRUB_CMDLINE_LINUX="console=ttyS0,19200n8"
GRUB_DISABLE_LINUX_UUID=true
GRUB_GFXPAYLOAD_LINUX="text"
GRUB_SERIAL_COMMAND="serial --speed=19200 --unit=0 --word=8 --parity=no --stop=1"
GRUB_TERMINAL=serial

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct