Questions tagged [grub2]

GENERAL GRUB2 SUPPORT IS OFF-TOPIC. Support questions may be asked on https://superuser.com. GRUB2 is a boot loader with support for modern day computer systems. It is meant to replace the older GRUB boot loader (now referred to as "GRUB Legacy").

Copied from https://wiki.gentoo.org/wiki/GRUB2:

GRUB2 is a boot loader with support for modern day computer systems. It is meant to replace the older GRUB boot loader (now referred to as "GRUB Legacy").

56 questions
0
votes
1 answer

GRUB memory map gives me weird values

I am trying to use grub in order to get the memory map, instead of going through the bios route. The problem is that grub seems to be giving me very weird values for some reason. Can anyone help with this? Relevant code: This is how I parse the…
user12312423
0
votes
2 answers

Create a grub script that auto detect EFI systems, and boot first one

I am working on an opensource project, bluebanquise, that aims to deploy baremetal infrastructures, and now that we support RHEL/CentOS 8 distributions, I wish to add other RHEL derivative distributions (Rocky Linux, Oracle Linux, Cloud Linux, etc…
oxedions
  • 61
  • 3
0
votes
1 answer

How early can I send data to a serial port on Linux boot?

I have an external serial peripheral that needs to be setup on Linux boot, on an embedded system. What I need is sending a short configuration string as early as possible during system boot, so my procedure is simply Set port to 115200 bps Send a…
LuC
  • 347
  • 2
  • 10
0
votes
1 answer

GRUB2 produces "multiboot header cannot be found" error when loading my kernel

I read GRUB Multiboot header not found but I cannot still load my kernel I tries to write the multiboot2 header directly in the .s file then link it. It is supposed to appear before all other segment: [kheader.s] .section .mbt2std tag_start: .long…
AlanCui
  • 137
  • 9
0
votes
1 answer

Hot to get the ELF symbols from GRUB2

I'm using the multiboot2 for my kernel, and I'm trying to get the ELF symbols from GRUB2, but I do not know how to do that. I have set .long MULTIBOOT_TAG_TYPE_ELF_SECTIONS in boot.s, also I got elf type, size, num, entsize and shndx from…
Zone233
  • 23
  • 1
  • 7
0
votes
1 answer

GRUB build fails to compile

I cloned grub from Github https://github.com/coreos/grub, however it fails to compile and gives error. The error seems obvious but the point is how the upstream code is not compiling. Am I doing anything wrong? I did below things to compile…
Naveen
  • 7,944
  • 12
  • 78
  • 165
0
votes
0 answers

Kernel throws GPF exception when booted with GRUB 2 instead of GRUB 0.97

I am trying to switch from GRUB 0.97 (stage2_eltorito) to GRUB 2, generating an ISO image that boots the operating system. However, I am facing a peculiar error. Just to give some context, I have recently set up some exception handling ISRs and two…
0
votes
1 answer

check file for corruption and fallback to golden image if necessary

How can I check in the grub.cfg file the sha1sum of a file and compare it with a stored number? If it is equal the image can loaded, if not it should switch back to the golden image I tried…
Max
  • 9
  • 3
0
votes
1 answer

Grub displays on-screen unable to get into bios

I installed GRUB and it only shows GRUB on the screen, I am unable to type anything. I am unable to get back into my bios to boot from usb. Any help would be appreciated
Slickness
  • 9
  • 2
0
votes
1 answer

Cross compiling "grub2" for live CD. How to use the "--prefix" option?

I make a live CD with custom linux and "grub2" on board. I compile the "grub2" from source code: HOST=x86_64-linux-gnu TARGET=x86_64-unknown-linux-uclibc CPPFLAGS="-I${INST_CROSS_TOOLS}/usr/include" LDFLAGS="-L${PREFIX_PATH}/usr/lib" \ ./configure…
Abradox
  • 117
  • 1
  • 7
0
votes
2 answers

grub2 on my embedded Board Corrupted, entered into grub rescue mode

I am working on a Intel board with centos running on it. My grub2 got corrupted. and entering into grub rescue mode Problem - whenever I reboot the device. grub rescue contains below info, when I do ls grub rescue> ls (hd0) (hd0,msdos3)…
anikhan
  • 1,147
  • 3
  • 18
  • 44
-1
votes
1 answer

Find location of GRUB2/Multiboot 'module' (aka initrd)

I am working on an OS, and need to load an INITRD (grub command "module") and can't find info on where (in RAM) the module is loaded to Does grub have a way of telling me or is it a fixed address or none of the above? Any help would be appreciated
-1
votes
1 answer

GRUB2 menu in early config

I'm trying to create a menu in the early config file of GRUB 2.04 in file early.cfg: menuentry foo { echo foo1 } menuentry bar { echo bar1 } I'm building core.img with: $ grub-mkimage -v -v -v -C xz -O i386-pc -p /prefix -o core.img -c…
pts
  • 80,836
  • 20
  • 110
  • 183
-1
votes
1 answer

GRUB2 and a custom File System

Writing OS experiment from scratch and curious about Grub2 and my FS I haven't tried very much with this just yet, at least not in practice. I've been reading about GRUB2 and how to set it up but am getting slightly lost. I apologize, I don't have…
-1
votes
2 answers

How do I get an initrd made out of a cpio archive loaded as the root device by grub2 in a distro-agnostic way?

I'm building an LFS (Linux From Scratch) system in a VM and so far I've managed to get a workable, desktop system, booting from a known device, /dev/sda1 in my case. I'm now trying to make a live system that boots from an ISO image. Instead of using…