On 10/23/19 1:57 PM, Ed Batalha wrote:
Trent wrote:
On 10/19/19 11:38 AM, Pierre Labastie wrote:
On 19/10/2019 17:07, Trent wrote:
On 10/17/19 6:26 AM, hazel debian wrote:
You should not mount the "BIOS boot" partition at /boot or
anywhere else. In fact you don't even need to have a filesystem on
it. GRUB installs its second part on that empty partition, and
the first part (which is in the dummy MBR) should locate it by its
physical address.
I think you may be confusing this with the "boot partition"
mentioned in the book, which is actually something quite
different. It is a normal partition with a filesystem on it that
is used to contain kernels when you are multibooting LFS with
other Linuxes. The team recommend having this common boot
partition for all your systems and mounting it on /boot in each of
them.
I finished the rebuild on a single partition, with the "bios_grub"
flag set.
Hmm, it's not what Hazel has written. On a GPT partition system,
you need at least two partitions (OK not mandatory, but easiest):
one which is the "bios boot"
(flag bios_grub in parted), which can be very small (1MB), and
another one for the system.
Of course, you may have more partitions if you want separate
partitions for /boot, /home, or /usr.
Do not format the "bios boot" partition, do not try to mount it.
Mount the second partition on /mnt/lfs instead. Build your system on
it, then you can install grub.
Pierre
Okay, I am already back on this again. I rebuilt the system again on
that branded SSD I mentioned I would try this time. I ran into an odd
problem during grub-install so I decided to rebuild again. The
rebuild is about halfway done.
On the first try for this SSD, I put only one partition on it of type
ext4.
When I ran "grub-install /dev/sdX --target i386-pc" it came back with
"grub does not support ext2."
Wow.
Rather than spend time on trying to figure that out, I went ahead and
cleared the drive out, then made two partitions.
/dev/sdX1 Unformated
"One quirk is that this magic “32kb gap” between sector 1 and the
first partition that is created /by convention/ for msdos-partitioned
disks does not exist in GPT. The solution is to create a specific
partition to hold the “embedded” copy of core.img; this partition must
have type |BIOS_BOOT|. The “grub-setup” utility (called by
grub-install) searches the GPT for the first partition of that type
and writes core.img there."
"For GPT (recommended), you need something like:
Number Start (sector) End (sector) Size Code Name
1 2048 4095 1024.0 KiB EF02 grub
2 4096 1052671 512.0 MiB 8300 boot
3 1052672 39456767 18.3 GiB 8300 debian
4 39456768 60428287 10.0 GiB 8200 Linux swap
5 429604864 468666367 18.6 GiB 8300 lfs-20190801
...
14 307765248 370679807 30.0 GiB 8300 lfs-9.0 "
The fist, unformatted partition needs to be type BIOS_BOOT, which is
code EF02 in Bruce's printout.
/dev/sdX2 ext
I am building now on /dev/sdX2.
With that, that is one thing not specifically clear. Do I run the
grub-install command for /dev/sdX, or for the unformatted partition
of /dev/sdX1?
For /dev/sdX
Thanks again!
Trent
I don't have GPT on my computers so I'm writing this based only on
what I've read previously about this subject.
Regards,
Ed
Thanks a bunch, Ed!
I was reading the URL you sent over on grub.
http://moi.vonos.net/linux/Booting_Linux_on_x86_with_Grub2/#installing-grub
It does mention, "The Grub utilities provide a command “grub-install”
which creates the files in |/boot/grub| and writes a program to a disk’s
Master Boot Record (MBR)."
I just wanted to be sure I am clear on it.
Trent
--
http://lists.linuxfromscratch.org/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page
Do not top post on this list.
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
http://en.wikipedia.org/wiki/Posting_style