LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 10-05-2019, 09:48 AM   #16
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593

remove all drives but the one can't get to boot
make sure legacy is disable in bios
boot from the rescue usb
run the following commands
Code:
vgchange -a y
mount /dev/mapper/centos-root /sysimage
mount /dev/sda2 /sysimage/boot
mount /dev/sda1 /sysimage/boot/efi
mount --bind  /dev /sysimage/dev
mount --bind /proc /sysimage/proc
mount --bind /sys /sysimage/sys
mount -o bind /run /sysimage/run
chroot /sysimage
grub2-install /dev/sda
grub2-mkconfig -o /boot/grub2/grub.cfg
with whatever console text editor you want to use
put a # in front of every line in /etc/fstab except for the following
Code:
/dev/mapper/centos-root /                       xfs     defaults        0 0
/dev/sda2		/boot                   xfs     defaults        0 0
/dev/sda1	        /boot/efi               vfat    umask=0077,shortname=winnt 0 0
/dev/mapper/centos-home /home                   xfs     defaults        0 0
/dev/mapper/centos-swap swap                    swap    defaults        0 0
exit out of the chroot, poweroff, remove usb and reboot

Last edited by colorpurple21859; 10-05-2019 at 11:29 PM.
 
Old 10-05-2019, 10:32 AM   #17
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by colorpurple21859 View Post
remove all drives but the one can't get to boot
make sure legacy is disable in bios
boot from the rescue usb
run the following commands
Code:
vgchange -a y
mount /dev/mapper/centos-root /sysimage
mount /dev/sda2 /sysimage/boot
mount /dev/sda1 /sysimage/boot/efi
mount --bind -o /dev /sysimage/dev
mount --bind -o /proc /sysimage/proc
mount --bind -o /sys /sysimage/sys
chroot /sysimage
grub2-install /dev/sda
grub2-mkconfig -o /boot/grub2/grub.cfg
with whatever console text editor you want to use
put a # in front of every line in /etc/fstab except for the following
Code:
/dev/mapper/centos-root /                       xfs     defaults        0 0
/dev/sda2		/boot                   xfs     defaults        0 0
/dev/sda1	        /boot/efi               vfat    umask=0077,shortname=winnt 0 0
/dev/mapper/centos-home /home                   xfs     defaults        0 0
/dev/mapper/centos-swap swap                    swap    defaults        0 0
exit out poweroff, remove usb and reboot
As for the bios, I'm not sure what you mean by legacy. The UEFI setup is a bit strange. Here is the manual, and I think what you're looking for is on page 87:

http://asrock.pc.cdn.bitgravity.com/...97M%20Pro4.pdf

As for the instructions:

Code:
$ mount /dev/mapper/centos-root /sysimage
mount: mount point /sysimage does not exist
 
Old 10-05-2019, 10:43 AM   #18
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593
Code:
mkdir /sysimage
before running the mount commands
 
Old 10-05-2019, 11:16 AM   #19
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593
Quote:
not sure what you mean by legacy.
on your system it is called csm under the boot screen. Leave as is for now, will change later if needed.

I edited the mount commands in post #16, I add a mount command and removed some of the -o

Last edited by colorpurple21859; 10-05-2019 at 11:35 PM.
 
Old 10-06-2019, 03:41 AM   #20
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,387

Rep: Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336Reputation: 2336
Quote:
not sure what you mean by legacy.
Legacy usually is the non-uefi boot option. It's the old way.
 
Old 10-06-2019, 10:57 AM   #21
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by business_kid View Post
Legacy usually is the non-uefi boot option. It's the old way.
Ya that is/was confusing because there's reference in the UEFI boot menu (F2). I don't think I've seen any legacy BIOS boot window. Only setting the UEFI back to defaults is what brought back other drives, which was the Legacy Only option in the drive options. .
 
Old 10-06-2019, 11:17 AM   #22
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by colorpurple21859 View Post
on your system it is called csm under the boot screen. Leave as is for now, will change later if needed.

I edited the mount commands in post #16, I add a mount command and removed some of the -o
OK, progressing with this:

Everything worked up until...

Code:
grub2-install /dev/sda
Installing for i386-pc platform
grub2-install: warning: this GPT partition label contains no BIOS Boot Partition; embedding wont' be possible.
grub2-install: warning: Embedding is not possible.  GRUB can only be installed in this setup by using blocklists.  However, blocklists are UNRELIABLE and their use is discouraged..
grub2-install: error: will not proceed with blocklists.
Note: this is a 64-bit machine. Previously I had to open up DHCP on the ethernet nic and install some grub package when chrooted.

Code:
yum -y reinstall grub2-tools grub2-efi shim grub2-efi-modules grub2-efi-x64-modules
Did not do that this time, so waiting for your clarity on this one.
 
Old 10-06-2019, 01:55 PM   #23
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593
You booted the usb in csm mode and not efi mode. Disabling csm in bios will prevent this. Page 86 in your manual
you may be able to just run the grub2-mkconfig after editing the /etc/fstab

Last edited by colorpurple21859; 10-06-2019 at 04:33 PM.
 
Old 10-07-2019, 11:18 AM   #24
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
OK, everything seems fantastic so far. Everything mounted, and I shoved in two other volumes previously formatted. So far so good. Now to see if the backup crons work and I'm golden.

I'll be monitoring, but again, thank you for all the help.
 
Old 10-07-2019, 11:43 AM   #25
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593
Great you got it working.
 
Old 10-07-2019, 11:44 AM   #26
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by colorpurple21859 View Post
Great you got it working.
So far so good. Not sure what we went through, but it's working. Much happy.
 
Old 10-07-2019, 11:48 AM   #27
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,369

Rep: Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593Reputation: 1593
I suspect it was a combination of your fstab and your grub.cfg causing the problem
 
Old 10-07-2019, 11:57 AM   #28
BeeRich
Member
 
Registered: Mar 2009
Location: Toronto, Canada
Distribution: CentOS7.something
Posts: 70

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by colorpurple21859 View Post
I suspect it was a combination of your fstab and your grub.cfg causing the problem
Yeah the movement of partitions and reassignment meant a new grub.cfg build, I'm guessing. My fstab was from the previous setup. Then the whole confusion about legacy bios in the UEFI...what a mess. 4 layers of confusion. But it's all documented now and apparently good to go, with a much better understanding.
 
  


Reply

Tags
boot err msg., emergency



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
/boot/boot/boot/boot/boot/ muddywaters SUSE / openSUSE 1 09-10-2005 06:08 AM
Problems, problems and more problems Yomaoni SUSE / openSUSE 4 06-09-2005 04:08 PM
Problems, problems, problems. Lets start with the soundcard Kre8ive Linux - Newbie 5 08-07-2003 01:20 AM
Problems, problems, problems. Lets start with the ES 1868 AudioDrive Kre8ive Linux - Newbie 1 08-06-2003 07:04 PM
Problems, Problems and More Problems! vijayendar Linux - Newbie 1 05-14-2003 11:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 06:25 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration