Re: CentOS 7 grub.cfg missing on new install

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]




----- Original Message ----- From: "Ned Slider" <ned@xxxxxxxxxxxxxx>
To: <centos@xxxxxxxxxx>
Cc: <jboyce@xxxxxxxxxxxxxxx>
Sent: Wednesday, December 10, 2014 8:53 PM
Subject: Re:  CentOS 7 grub.cfg missing on new install


On 10/12/14 18:13, Jeff Boyce wrote:
Greetings -

The short story is that got my new install completed with the
partitioning I wanted and using software raid, but after a reboot I
ended up with a grub prompt, and do not appear to have a grub.cfg file.
So here is a little history of how I got here, because I know in order
for anyone to help me they would subsequently ask for this information.
So this post is a little long, but consider it complete.

. . . trim . . .

I then installed GRUB2 on /dev/sdb1 using the following command:
root#  grub2-install /dev/sdb1
   Results:  Installing for x86_64-efi platform.  Installation finished.
No error reported.


The upstream docs (see below) seem to suggest 'grub2-install /dev/sdb'
rather than /dev/sdb1 (i.e, installing to the device rather than a
partition on the device). I don't know if this is the cause of your issue.

I rebooted the system now, only to be confronted with a GRUB prompt.
Thinking that this is a good opportunity to for me to learn to rescue a
system since I am going to need to understand how to recover from a disk
or raid failure, I started researching and reading.  It takes a little
bit of work to understand what information is valuable when a lot of it
refers to GRUB (not GRUB2) and doesn't make reference to UEFI booting
and partitions. I found this Ubuntu wiki as a pretty good source
https://help.ubuntu.com/community/Grub2/Troubleshooting#Search_.26_Set


I found the upstream documentation for grub2 to be useful:

https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/System_Administrators_Guide/ch-Working_with_the_GRUB_2_Boot_Loader.html

Included is a procedure for completely reinstalling grub2 which might
help you recover.

. . . trim . . .

Ned, thanks for your insight. I feel like I have been sleeping with that RH7 document the last day or so trying to understand what I messed up and how to recover, I just didn't reference it in my post. Your conclusion about grub2-install being directed to the partition rather than the device may be correct, and is about the only little detail that I see that may have been wrong. The weird thing is that the installation should have put everything in the proper place on the primary drive, and my grub2-install command is being directed at putting it on the secondary drive. That is what is confusing me as the proper grub files should have been on the primary drive, allowing me to boot from there. It would have been nice if I had happened to check for the grub files before the failed reboot, or immediately after the installation. I think at this point I am going to not try and recover, but just re-install from scratch. I have gained enough knowledge in the past few days learning about grub that at least I know the general process and how to get started, but at this point I want to make sure I have a good clean system on the initial install. Thanks to others who at least took the time to read my long post.

Jeff

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos




[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux