LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook
User Name
Password
Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).

Notices


Reply
  Search this Thread
Old 06-22-2022, 09:53 PM   #1
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Rep: Reputation: 1
Forcing grub to install in it's fallback directory with a LiveUSB!!


So being as I am NOT a fan of Microsoft or ANY of it's products so when I was given a Laptop with Windows 10 installed my first thought was to trash it and install Linux.

I tried over and over in MANY different ways to get Linux to install, but they failed every time. One I could see as an input error or just plain human error, but 30 times and I'm diagnosing hardware issues (More thinking those are my issues as I have very little knowledge to diagnose anything and I know it)

I researched the issue to death and was finally made aware that my computer was "Forcing" the Linux software to look for GRUB in the SECONDARY Grub-Install whereas it was installed in the primary location therein causing Linux to fail every time I tried... Fortunately for me this knowledge came with a solution of installing Endless OS as it installs Grub into it's secondary or fallback directory as a default.

I installed Endless OS and succeeded in getting Microsoft to go away, but Endless OS is a Fedora Based Operating system and for more than a decade I've been using Debian based Systems. Being as they are both Linux they are close enough not to be too much an issue to learn and still keeps me from using a Microsoft product as an Operating System so on a scale of 1 to 10 my issues went from a 22 to a 4 so other than a personal project I can weed through all the Microsoft solutions I am NEVER going to even try as I would see that as a step in the wrong direction.

So as explaining my issue and putting it in the title will be seen as a "Rant" with no Question...

HOW DO I GET GRUB TO INSTALL INTO IT'S SECONDARY/FALLBACK DIRECTORY? WHERE IS THAT SECONDARY INSTALLATION DIRECTORY? IS THERE A DEBIAN BASED DISTRIBUTION THAT I CAN INSTALL BECAUSE IT INSTALLS INTO SAID DIRECTORY THAT ANYONE KNOWS OF?

Three questions and NONE of them are opinions and all of them address a problem that Endless OS seems to have found enough of a niche to develop a software to exploit so maybe someone else thought to be an idea, but used Debian Systems to design theirs giving people an option to see if Linux is their problem or their computer is and NOT HAVE a two week timeframe where they have 0 information as to how to do it with their computer if this becomes an issue for them.

Last edited by WinterStreet; 06-22-2022 at 10:37 PM.
 
Old 06-22-2022, 11:06 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,160

Rep: Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125
For some-one who claims over a decade experience, this reads as yet another example of the xyproblem.

Show us some real data rather than diatribe - either the report from bootinfoscript or the one from boot-repair. From a liveCD is fine if you can't get an overlay for Endless.
 
Old 06-22-2022, 11:37 PM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Which directories are those?
Which is grub's primary install directory?
Which is grub's "SECONDARY/FALLBACK" directory?

Quote:
Originally Posted by WinterStreet View Post
So being as I am NOT a fan of Microsoft or ANY of it's products so when I was given a Laptop with Windows 10 installed my first thought was to trash it and install Linux.

I tried over and over in MANY different ways to get Linux to install, but they failed every time. One I could see as an input error or just plain human error, but 30 times and I'm diagnosing hardware issues (More thinking those are my issues as I have very little knowledge to diagnose anything and I know it)

I researched the issue to death and was finally made aware that my computer was "Forcing" the Linux software to look for GRUB in the SECONDARY Grub-Install whereas it was installed in the primary location therein causing Linux to fail every time I tried... Fortunately for me this knowledge came with a solution of installing Endless OS as it installs Grub into it's secondary or fallback directory as a default.

I installed Endless OS and succeeded in getting Microsoft to go away, but Endless OS is a Fedora Based Operating system and for more than a decade I've been using Debian based Systems. Being as they are both Linux they are close enough not to be too much an issue to learn and still keeps me from using a Microsoft product as an Operating System so on a scale of 1 to 10 my issues went from a 22 to a 4 so other than a personal project I can weed through all the Microsoft solutions I am NEVER going to even try as I would see that as a step in the wrong direction.

So as explaining my issue and putting it in the title will be seen as a "Rant" with no Question...

HOW DO I GET GRUB TO INSTALL INTO IT'S SECONDARY/FALLBACK DIRECTORY? WHERE IS THAT SECONDARY INSTALLATION DIRECTORY? IS THERE A DEBIAN BASED DISTRIBUTION THAT I CAN INSTALL BECAUSE IT INSTALLS INTO SAID DIRECTORY THAT ANYONE KNOWS OF?

Three questions and NONE of them are opinions and all of them address a problem that Endless OS seems to have found enough of a niche to develop a software to exploit so maybe someone else thought to be an idea, but used Debian Systems to design theirs giving people an option to see if Linux is their problem or their computer is and NOT HAVE a two week timeframe where they have 0 information as to how to do it with their computer if this becomes an issue for them.
 
Old 06-22-2022, 11:56 PM   #4
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by syg00 View Post
For some-one who claims over a decade experience, this reads as yet another example of the xyproblem.

Show us some real data rather than diatribe - either the report from bootinfoscript or the one from boot-repair. From a liveCD is fine if you can't get an overlay for Endless.
If it is not broken I have no real reason to fix it so the fact that I have been installing Linux for a Decade and THIS time I run into issues... I have a basic understanding of the inner workings of Linux (enough to work Linux day to day). As to backups, I back up important items and an Operating System that I'm not comfortable with usually does not make the cut, but if it important to keep around a way to start over I do so as an undesirable situation is something to rectify and not hold on to.
 
Old 06-23-2022, 12:08 AM   #5
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by ondoho View Post
Which directories are those?
Which is grub's primary install directory?
Which is grub's "SECONDARY/FALLBACK" directory?
These are all questions that I have no answer to the last being one of MY main questions so I do not understand the point of this? Other than to say You think my post is long-winded... If that is the point, I'm thinking your just upset because you cannot answer any of those questions to answer, but still want to spout off and be recognized because there was nothing to answer ANYTHING asked, so it is just to get noticed.
 
Old 06-23-2022, 05:08 AM   #6
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,599

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
If the computer you have had windows 10 installed on it it was almost certainly a UEFI install. Do you know the difference between UEFI and Legacy/CSM? How old is this computer and what type is it (HP, Dell, Toshiba, Lenovo,etc.)?

On a Legacy install the OS you are installing which you want to be in charge of booting needs to install some Grub code in the MBR with most of the Grub files on the OS system partition. With a UEFI install, this is not done, some Grub boot code is installed on the EFI partition and most on the OS system partition. Do you have an EFI partition? Do you have a directory there for the Endless OS? Apparently you can boot it, correct?

Quote:
HOW DO I GET GRUB TO INSTALL INTO IT'S SECONDARY/FALLBACK DIRECTORY?
I've never heard of anything like this nor am I familiar with Endless OS. Could you post a link to the site where you got this information?
 
Old 06-23-2022, 07:33 AM   #7
Debian6to11
Member
 
Registered: Jan 2022
Location: Limassol, Cyprus
Distribution: Debian
Posts: 382
Blog Entries: 1

Rep: Reputation: 71
I only have two and half to three years of Linux experience. Still, one of the easiest things to do is wiping out the disk and install a different operating system on it. I could do that since day one.
Since you cannot answer the questions of post #3, how do you have ten years of experience?


Quote:
HOW DO I GET GRUB TO INSTALL INTO IT'S SECONDARY/FALLBACK DIRECTORY? WHERE IS THAT SECONDARY INSTALLATION DIRECTORY? IS THERE A DEBIAN BASED DISTRIBUTION THAT I CAN INSTALL BECAUSE IT INSTALLS INTO SAID DIRECTORY THAT ANYONE KNOWS OF?
How do know about these? Where did you find them? What part of the installation told you that? And as far as I know, any Linux distribution would install in the same way, or install as it is told to.
 
Old 06-23-2022, 02:32 PM   #8
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,410

Rep: Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598
Quote:
Which is grub's primary install directory?
grub-install/grub2-install installs grub files in /boot/grub on debian based systems and /boot/grub2 on fedora based systems.
in legacy mode grub-install/grub2-install install grub boot code to the mbr of the drive, on uefi systems installs grubx64.efi file to /boot/efi/EFI/<distro directory> if the efi partition exist and is mounted. grub-mkconfig/update-grub generates the /boot/grub(2)/grub.cfg file that generates the grub menu seen at boot. /etc/default/grub and the files in /etc/grub.d/ are used to generate the /boot/grub(2)/grub.cfg. Some distros in uefi mode there is a /boot/efi/EFI/<distro directory>/grub.cfg that sets the grub prefix from the efi partition back to /boot/grub(2)/
Because of the versatility of grub there are exceptions to how grub-install works with the different distros

As far as grub packages go, Each distro packages grub differently

Last edited by colorpurple21859; 06-23-2022 at 02:38 PM.
 
1 members found this post helpful.
Old 06-23-2022, 02:52 PM   #9
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by yancek View Post
Do you have an EFI partition? Do you have a directory there for the Endless OS? Apparently you can boot it, correct?

I've never heard of anything like this nor am I familiar with Endless OS. Could you post a link to the site where you got this information?
First off it is a Lenovo Ideapad 320 and as stated I have been installing Linux systems for a Decade so if it was as easy as booting Legacy it would be done and over with. I have tried 4 ways to Sunday to get them to install until I found this post and it sounds like you want to know rather than say do this and expect it to work so... https://bugs.launchpad.net/ubuntu/+s...r/+bug/1832282 This should have been in my initial posting as it probably explains my issue better than I can, but as no-one has asked as to where I got my information it had slipped my mind. ;P
 
Old 06-23-2022, 03:28 PM   #10
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,410

Rep: Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598
From your link
Quote:
Endless, unlike other distributions, copies their bootloader to the fallback location (EFI/BOOT/bootx64.efi) on the EFI partition. Other distributions don't do that because they don't want to fight with Windows for ownership of this fallback boot loader. And your laptop is one the few bad ones that always boots the fallback entry regardless of what is in the EFI variables.
This is your issue: And your laptop is one the few bad ones that always boots the fallback entry regardless of what is in the EFI variables. The fix is to copy EFI/<distro directory>/grubx64.efi to EFI/BOOT/bootx64.efi on the EFI partition. Have you attempted to go into the bios/firmware to change the default boot.
I have a hp that efibootmgr doesn't work to set the EFI default boot entry, however I can from within the bios/firmware setup menu.

Last edited by colorpurple21859; 06-23-2022 at 03:32 PM.
 
1 members found this post helpful.
Old 06-23-2022, 06:00 PM   #11
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by colorpurple21859 View Post
From your link
This is your issue: And your laptop is one the few bad ones that always boots the fallback entry regardless of what is in the EFI variables. The fix is to copy EFI/<distro directory>/grubx64.efi to EFI/BOOT/bootx64.efi on the EFI partition. Have you attempted to go into the bios/firmware to change the default boot.
I have a hp that efibootmgr doesn't work to set the EFI default boot entry, however I can from within the bios/firmware setup menu.
Been there, Done that... The LiveUSB seems to format the directory If I tell it to or not. Which is why I'm looking for a way to force the LiveUSB to do it within the install. As I have said Endless OS has found a way, but I would like to tweak that idea to my purposes so I am more comfortable and in the meantime I get to play around and figure things out.

I have been doing this for a Decade so I am familiar with the basics and THIS particular laptop is doing whatever it can to make sure Linux cannot be installed and I found a way to do so. Now I am looking for a Distro based on the Debian Distro or a way to alter the LiveUSB install to install the way this particular Laptop will allow me to force onto it.

With this Laptop normally doesn't work so you hear hoof-beats don't think Horses or Zebras, think the mules got loose from the petting zoo, what spooked them? Throw the box out (I know I sure did) .

Last edited by WinterStreet; 06-23-2022 at 07:32 PM. Reason: Hit the mouse button and posted before I had completed it
 
Old 06-23-2022, 06:58 PM   #12
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,410

Rep: Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598
Quote:
but Endless OS is a Fedora Based Operating system and for more than a decade I've been using Debian based Systems. Being as they are both Linux they are close enough not to be too much an issue to learn
When it comes to the grub boot loader in uefi mode, fedora does things differently than debian

Quote:
The LiveUSB seems to format the directory If I tell it to or not.
explain this, a live usb won't touch a efi partition on it's own.

Last edited by colorpurple21859; 06-23-2022 at 07:02 PM.
 
Old 06-24-2022, 12:24 AM   #13
WinterStreet
LQ Newbie
 
Registered: Jun 2022
Posts: 13

Original Poster
Rep: Reputation: 1
Talking

Quote:
Originally Posted by colorpurple21859 View Post
When it comes to the grub boot loader in uefi mode, fedora does things differently than debian
This being said I may have a new one built by the time someone decides to build a Debian based system and as I have no rush to find a solution as getting Microsoft off the computer was a big deal to me and this is more housekeeping (Annoying, but the thought of NOT doing makes my skin crawl)

Quote:
Originally Posted by colorpurple21859 View Post
explain this, a live usb won't touch a efi partition on it's own.
Explain how a software that installs onto THOUSANDS of computers EVERY day fails to install on this Laptop. Installs fail every time because they don't do things the way they are SUPPOSED to be done. This is in my opinion is where the failure to communicate comes into play. The COMPUTER has a BUG that PREVENTS the install of Linux as it looks at the FALLBACK destination for the GRUB install that was installed in the primary location and if I install grub into what I think is the backup directory (Which either I have been misinformed or it gets formatted before the install happens.

Supposed to or not... There is my issue, my Laptop has a BUG that prevents any NORMAL installation of Linux and I'm hopeful that Debian systems can handle the install, but if not it is not the end of the world. This was a computer that someone else didn't want for whatever reason (I'm guessing the Bug affects Windows somehow that made it inconvenient to keep and not just buy a new one). This is a project computer so No huge ramifications to taking my time and getting it the way I want.

Last edited by WinterStreet; 06-24-2022 at 01:24 AM.
 
Old 06-24-2022, 04:42 AM   #14
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,599

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
Quote:
This should have been in my initial posting as it probably explains my issue better than I can, but as no-one has asked as to where I got my information it had slipped my mind.
Yes, that link should have been in your initial post, thanks for posting it. You were asked where you got that information in posts 6 and 7.

The solution on that page is the same as the solution proposed in post 10. You indicate you have tried that already and it seems pretty bizarre that it didn't work so I guess the problem is with your computer. If Endless installs to that location, installing Debian and then copying/renaming its boot file as suggested to that location should work. So the solution on the page you linked doesn't actually work or at least not on some machines.

Quote:
Which is why I'm looking for a way to force the LiveUSB to do it within the install.
Based on the information you have posted, the Debian installer does not give you such options and I expect most other Linux systems would not give you that option. You would probably need to extract or loop mount the Endless iso file and search through it for the files related to the install of Grub and if you find them, extract/loop mount Debian and copy those files to the extracted Dbian and recreate the Debian iso. Hope you're up for a challenge and good luck.

Last edited by yancek; 06-24-2022 at 03:22 PM.
 
1 members found this post helpful.
Old 06-24-2022, 02:50 PM   #15
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,410

Rep: Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598Reputation: 1598
From within the installed os, either by booting or chroot, make sure the efi partition is mounted to /boot/efi
Code:
grub-install --removable
 
  


Reply



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
Infinite Grub Loop: GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB GRUB... beeblequix MEPIS 2 11-02-2013 10:56 PM
How to edit initrd to fit your liveUSB - liveUSB preparation (openSUSE and others) deckoff Linux - General 7 01-08-2012 02:58 AM
Interpretation required for '(none) dhcpd: Sending on Socket/fallback/fallback-net' ttomsant Linux - Newbie 0 04-07-2009 02:31 PM
forcing traffic through certain route(forcing source ip) taltman Linux - Networking 1 12-26-2007 01:07 PM
Booting my new ubuntu install = "GRUB GRUB GRUB GRUB GRUB" etc. dissolved soul Ubuntu 2 01-13-2007 12:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook

All times are GMT -5. The time now is 01:40 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
Open Source Consulting | Domain Registration