LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 11-09-2017, 03:27 PM   #1
horizn
Member
 
Registered: Jan 2015
Location: UK and Poland
Distribution: Slackware + Debian + Ubuntu
Posts: 105

Rep: Reputation: Disabled
UEFI stopped working after CMOS clear


Hi,
I had to clear CMOS, and unfortunately after that computer has stopped booting. I have tried to rescue it as mentioned here:
https://docs.slackware.com/howtos:sl...uefi_and_elilo.
But with no luck.
EFI is on /dev/sda1, root is on /dev/sda2.
1. There are no elilo.efi on Slackware DVD.
2. I have mounted /dev/sda1 under /mnt and /dev/sda2 under /mnt/boot, then chroot to /mnt and reinstalled elilo but with no result.

Any ideas?
 
Old 11-09-2017, 03:31 PM   #2
Uncle Lumpy
LQ Newbie
 
Registered: Feb 2010
Posts: 29

Rep: Reputation: 10
After clearing the CMOS, did you check to see that UEFI boot was still the default rather than legacy mode?

Also, I don't know much about UEFI, but is it possible that clearing the CMOS deleted the UEFI entry telling the computer where to find the boot section? Smarter folks than I will have to jump in here. If this is the case, I believe there is a command to let the UEFI part of the computer know where to find the efi partition.

Take it away smarter people!

Lumpy
 
Old 11-09-2017, 03:37 PM   #3
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida panhandle
Distribution: slackware64-current, puppy, ubuntu
Posts: 2,220

Rep: Reputation: 319Reputation: 319Reputation: 319Reputation: 319
Quote:
I have mounted /dev/sda1 under /mnt and /dev/sda2 under /mnt/boot
mount /dev/sda2 under /mnt and then either mount /dev/sda1 under /mnt/boot/efi before chrooting or /boot/efi after chrooting. before reinstalling elilo.
 
Old 11-09-2017, 03:55 PM   #4
horizn
Member
 
Registered: Jan 2015
Location: UK and Poland
Distribution: Slackware + Debian + Ubuntu
Posts: 105

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Uncle Lumpy View Post
After clearing the CMOS, did you check to see that UEFI boot was still the default rather than legacy mode?

Also, I don't know much about UEFI, but is it possible that clearing the CMOS deleted the UEFI entry telling the computer where to find the boot section? Smarter folks than I will have to jump in here. If this is the case, I believe there is a command to let the UEFI part of the computer know where to find the efi partition.

Take it away smarter people!

Lumpy
Of course, I have changed it back to UEFI.
 
Old 11-09-2017, 03:56 PM   #5
horizn
Member
 
Registered: Jan 2015
Location: UK and Poland
Distribution: Slackware + Debian + Ubuntu
Posts: 105

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by colorpurple21859 View Post
mount /dev/sda2 under /mnt and then either mount /dev/sda1 under /mnt/boot/efi before chrooting or /boot/efi after chrooting. before reinstalling elilo.
Will check, and let you know.
 
Old 11-09-2017, 05:02 PM   #6
horizn
Member
 
Registered: Jan 2015
Location: UK and Poland
Distribution: Slackware + Debian + Ubuntu
Posts: 105

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by colorpurple21859 View Post
mount /dev/sda2 under /mnt and then either mount /dev/sda1 under /mnt/boot/efi before chrooting or /boot/efi after chrooting. before reinstalling elilo.
No luck.
 
Old 11-09-2017, 05:51 PM   #7
bassmadrigal
Senior Member
 
Registered: Nov 2003
Location: Newport News, VA
Distribution: Slackware
Posts: 4,571

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
I'm wondering if you reset your CMOS if it resets the EFI partitions stored within the firmware. If that is the case, you'd need to re-register the efi partition with the firmware. The easiest way to do that (probably... I'm still semi-new to UEFI booting) is to boot the installation media in UEFI mode. Then you need to mount your partitions, although, I tend to be lazy and just run setup and go through the prompts until it asks where the install files are. Once you get to that point, it should've mounted your root, any other partitions you specified and your EFI partition. Once that is done, you'll need to bind mount your /sys/, /dev/, and /proc/ folders to the mounted filesystem.

Code:
mount -o bind /sys/ /mnt/sys/
mount -o bind /dev/ /mnt/dev/
mount -o bind /proc/ /mnt/proc/
After that, you'll need to chroot your mounted partitions.

Code:
chroot /mnt
Now, you can run eliloconfig and it will recreate your elilo.conf (if you have any customizations to it, save it elsewhere so you can restore it after) and register your efi partition with the firmware. After that is done, you should be able to reboot and hopefully boot off your normal drive.
 
1 members found this post helpful.
Old 11-09-2017, 09:02 PM   #8
Launfal
Member
 
Registered: Jun 2014
Location: Ohio, USA
Posts: 65

Rep: Reputation: 49
Try this

I had something similar happen to me when I flashed the bios on my office rig. This is what I did to fix it.

1.Boot from the USB boot disk you made when you installed Slack.
2.Run pkgtool and select settings > reinstall elilo > install boot menu entry.
3.Reboot as normal and see if that doesn't fix it.
 
Old 11-10-2017, 03:36 AM   #9
aragorn2101
Member
 
Registered: Dec 2012
Location: Mauritius
Distribution: Slackware
Posts: 517

Rep: Reputation: 245Reputation: 245Reputation: 245
Quote:
Originally Posted by bassmadrigal View Post
I'm wondering if you reset your CMOS if it resets the EFI partitions stored within the firmware. If that is the case, you'd need to re-register the efi partition with the firmware.
Well spotted bassmadrigal! I also think this is what happened.

But, horizn, as a precaution, just backup/rename the existing bootloader found on the EFI partition. If eliloconfig does not work, you can still register the old elilo.efi from EFI partition using (after chroot):
Code:
efibootmgr -c -g -d /dev/sda -p 1 -w -L "ELILO" -l '\EFI\Slackware\elilo.efi'
-d /dev/sda: first hard drive
-p 1: first partition
thus, /dev/sda1
 
1 members found this post helpful.
Old 11-11-2017, 09:34 AM   #10
horizn
Member
 
Registered: Jan 2015
Location: UK and Poland
Distribution: Slackware + Debian + Ubuntu
Posts: 105

Original Poster
Rep: Reputation: Disabled
Thanks to all for trying helping me. Unfortunately my laptop BIOS must be buggy somehow. I wasn't able to boot neither from USB stick nor CDROM in UEFI mode, so I have decided to disable UEFI and install lilo instead. It is working now. Thanks again.
 
Old 11-11-2017, 11:04 AM   #11
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida panhandle
Distribution: slackware64-current, puppy, ubuntu
Posts: 2,220

Rep: Reputation: 319Reputation: 319Reputation: 319Reputation: 319
Some efi firmware requires that the boot loader file be in efi/boot directory on the efi partition and named as bootx64.efi. So maybe copy the files from the slackware directory on the efi partition to efi/boot/ and renaming the elilo.efi to bootx64.efi
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Any BIOS\CMOS\UEFI tweaks that are worthwhile? linustalman Linux - Hardware 3 07-03-2017 02:30 PM
Nagios web interface stopped working afer I got postfix working erosbach Linux - Newbie 1 03-27-2017 03:39 PM
Can't get dual boot, win 7 uefi and elementary freya os uefi working shywolf Linux - Newbie 4 12-10-2015 07:14 PM
Has anyone got UEFI working? BeaverusIV Arch 2 07-31-2011 07:47 AM
Can't clear CMOS Password adamis Linux - Hardware 3 10-27-2006 02:08 PM

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

All times are GMT -5. The time now is 07:20 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration