Score:0

Bcdboot equivalent for Linux (Lubuntu and Ubuntu)

mg flag

All my searches have turned up a bunch of boot loaders, grub, grub2, etc. I have read about the boot repair iso. However I like a manual way of doing it.

For example I can easily in Windows:

bcdboot c:\windows /s e: /f UEFI  # changing volume letters as needed

And booting is fixed.

There has to be a simple as this way to take a blank efi Ubuntu or Lubuntu partition and put the boot code on it. Any help finding the command lines (terminal lines) to achieve this. Thanks.

guiverc avatar
cn flag
Your `bcdboot` command is run using details specific to the OS/release you're using (ie. "c:\windows" is a directory of the drive label C: currently in use), so don't forget your windows command is not *generic*. The commands current Ubuntu/Lubuntu uses that is closest is `grub-install` which is coded to use the GRUB version specific to your *unstated* ubuntu 2 release (it'll be a GRUB 2 version for your *unstated* release, ie. it'll be the appropriate version for used where the command is run) If you've replaced the default GRUB boot loader command will differ.
Jim Whitaker avatar
mg flag
Lubuntu 22.04 on uefi. Where do I run grub-install, from an install disk? I am just trying to understand how to make a lubuntu installation boot up if I had the 300mb efi partition blank and the root partition is fine, has all the data, etc. I am not interested in a "boot menu". I have seen the term efibootmgr in some post, what does it do. Linux has to have an equal one liner similar to what bcdboot does in WIndows, thanks.
guiverc avatar
cn flag
Grub exists in multiple stages. the first stage exists on the MBR or ESP (*uEFI System Partition*) and this is what `grub-install` writes.. It gets the rest of the details from the system that is running (*just like your `bcdboot` got details from the running windows*) where the later stages of grub (stages 1.5, 2 etc) exist in the `/boot/grub/` directory of the GNU/Linux partition (Ubuntu in this case). `update-grub` will deal with those, `grub-install` will write the MBR or ESP as required by the system that is running (*you specify drive, as each drive can by standard have its own MBR/ESP*)
Jim Whitaker avatar
mg flag
Okay, if I currently have a blank 300mb fat32 efi partition with nothing on it from where do I run grub-install. Assuming The system doesn't currently boot up. And what exactly would the terminal command look like? That's what I'm after. And what is efibootmgr?
Jim Whitaker avatar
mg flag
After finding and trying things from https://help.ubuntu.com/community/Grub2/Installing All I got is error after error. The efi partition was sda1 the main partition sda2, it wouldn't even mount. I tryed ```sudo mount /dev/sda2 /mnt``` then ```sudo grub-install --boot-directory=/mnt/boot /dev/sda``` But errors, because probably ```sudo mount /dev/sda1 /mnt/boot``` wouldn't mount. A not found in fstab I believe it said. Folks there has got to be a way (workable easy way) to write boot code to sba1. Anybody?
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.