注意:

The Funtoo Linux project has transitioned to "Hobby Mode" and this wiki is now read-only.

Difference between revisions of "Boot Methods"

From Funtoo
Jump to navigation Jump to search
 
(5 intermediate revisions by one other user not shown)
Line 1: Line 1:
It used to be that booting a PC-compatible system didn't involve very many choices -- there was only one way to do it. All hard drives uses Master Boot Records, and were partitioned using the MBR partition scheme. Then, along came EFI and UEFI, which are new-style firmware designed to boot systems, along with GPT partition tables to support disks larger than 2.2TB. All of the sudden, we then had a variety of options to boot Linux systems, turning what once was a one-method-fits-all approach into something a lot more complex.
<languages/>
<translate>
It used to be that booting a PC-compatible system didn't involve very many choices -- there was only one way to do it. All of our desktops and servers had a standard BIOS, all our hard drives used Master Boot Records, and were partitioned using the MBR partition scheme. Then, along came EFI and UEFI, which are new-style firmware designed to boot systems, along with GPT partition tables to support disks larger than 2.2TB. All of the sudden, we then had a variety of options to boot Linux systems, turning what once was a one-method-fits-all approach into something a lot more complex.</translate>
<translate>
=== BIOS + GRUB (MBR) ===


=== Pure MBR + GRUB ===
{{Note|This option is the "old school" way to boot Funtoo Linux, as documented in our [[Install|Install Guide]]. This method uses traditional MBR partitions, which have existed since the origin of the PC. }}
 
{{Note|This option is the "classic" way to boot Funtoo Linux and uses traditional MBR partitions, which have existed since the origin of the PC. This method is detailed in our Install Guide.}}


Here is the typical disk layout:
Here is the typical disk layout:
Line 17: Line 19:
# Extra boot-related code is loaded by the GRUB stage1 from the <tt>/boot</tt> filesystem on the disk.
# Extra boot-related code is loaded by the GRUB stage1 from the <tt>/boot</tt> filesystem on the disk.


Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.
Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.</translate>
 
<translate>
=== GPT + GRUB ===
=== BIOS + GRUB (GPT) ===


This is a more modern way to boot Linux. It uses MBR for booting but uses the more modern GPT partition scheme. Here's the disk layout:
This is a more modern way to boot Linux. It uses MBR for booting but uses the more modern GPT partition scheme. Here's the disk layout:
Line 34: Line 36:
# Extra boot-related code is loaded by the GRUB stage1 from a small (a few MB) GPT partition on the disk.
# Extra boot-related code is loaded by the GRUB stage1 from a small (a few MB) GPT partition on the disk.


Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.
Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.</translate>
<translate>
=== UEFI + GRUB ===


=== UEFI + GRUB ===
{{Note|This method is documented in our [[Install|Install Guide]] as the "new school" UEFI boot method.}}


UEFI is a new-style firmware that is used for booting. It is generally available on all new PCs (2012 and newer) and may be available on older systems as well. Here's the disk layout:
UEFI is a new-style firmware that is used for booting. It is generally available on all new PCs (2012 and newer) and may be available on older systems as well. Here's the disk layout:
Line 51: Line 55:
# UEFI can read from <tt>vfat</tt> partitions directly, which is why we use <tt>vfat</tt> instead of the normal <tt>ext2</tt> for <tt>/boot</tt>.
# UEFI can read from <tt>vfat</tt> partitions directly, which is why we use <tt>vfat</tt> instead of the normal <tt>ext2</tt> for <tt>/boot</tt>.


Now, the boot loader is able to run and load the Linux kernel and initramfs from the <tt>vfat</tt> <tt>/boot</tt> filesystem, and start Funtoo Linux.
Now, the boot loader is able to run and load the Linux kernel and initramfs from the <tt>vfat</tt> <tt>/boot</tt> filesystem, and start Funtoo Linux.</translate>
 
<translate>
=== Pure UEFI ===
=== Pure UEFI ===


A Pure UEFI boot is also possible. The partitioning scheme is the same as the UEFI + GRUB scheme, above.
A Pure UEFI boot is also possible. The partitioning scheme is the same as the UEFI + GRUB scheme, above. This boot method is documented in detail in our [[Pure UEFI Boot Guide]].


Here's how this boot scheme works:
Here's how this boot scheme works:


# UEFI (contained in your motherboard's firmware) loads the Bootmanager entry from the RW NVRAM inside your motherboard.
# UEFI (contained in your motherboard's firmware) loads the Bootmanager entry from the RW NVRAM inside your motherboard.
# UEFI loads the Linux kernel STUB and initramfs directly, and runs the Linux kernel to start Funtoo Linux.
# UEFI loads the Linux kernel STUB and initramfs directly, and runs the Linux kernel to start Funtoo Linux.</translate>

Latest revision as of 15:31, January 22, 2017

It used to be that booting a PC-compatible system didn't involve very many choices -- there was only one way to do it. All of our desktops and servers had a standard BIOS, all our hard drives used Master Boot Records, and were partitioned using the MBR partition scheme. Then, along came EFI and UEFI, which are new-style firmware designed to boot systems, along with GPT partition tables to support disks larger than 2.2TB. All of the sudden, we then had a variety of options to boot Linux systems, turning what once was a one-method-fits-all approach into something a lot more complex.

BIOS + GRUB (MBR)

   Note

This option is the "old school" way to boot Funtoo Linux, as documented in our Install Guide. This method uses traditional MBR partitions, which have existed since the origin of the PC.

Here is the typical disk layout:

  • MBR (master boot record) at beginning of boot disk
  • MBR partition 1, /dev/sda1 is the /boot filesystem (typically ext2)
  • MBR partition 2, /dev/sda2 is swap.
  • MBR partition 3, /dev/sda3 is the / (root) filesystem.

Here's how the boot process works:

  1. The system BIOS loads the MBR from your boot disk (containing stage1 of the GRUB boot loader) and runs it.
  2. Extra boot-related code is loaded by the GRUB stage1 from the /boot filesystem on the disk.

Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.

BIOS + GRUB (GPT)

This is a more modern way to boot Linux. It uses MBR for booting but uses the more modern GPT partition scheme. Here's the disk layout:

  • The protective MBR is used for booting.
  • GPT partition 1, /dev/sda1 is the /boot filesystem (typically ext2)
  • GPT partition 2 type 0xEF02, /dev/sda2 is the boot loader partition (this contains a fake MBR).
  • GPT partition 3, /dev/sda3 is swap.
  • GPT partition 4, /dev/sda4 is the / (root) filesystem.

Here's how this hybrid scheme works:

  1. The system BIOS loads the fake MBR from your boot disk(/dev/sda2) (containing stage1 of the GRUB boot loader) and runs it.
  2. Extra boot-related code is loaded by the GRUB stage1 from a small (a few MB) GPT partition on the disk.

Now, the boot loader is able to run and load the Linux kernel and initramfs, and start Funtoo Linux.

UEFI + GRUB

   Note

This method is documented in our Install Guide as the "new school" UEFI boot method.

UEFI is a new-style firmware that is used for booting. It is generally available on all new PCs (2012 and newer) and may be available on older systems as well. Here's the disk layout:

  • no MBR is installed or required
  • GPT partition 1, /dev/sda1 is the /boot filesystem (vfat aka "FAT32").
  • GPT partition 2, /dev/sda2 is swap.
  • GPT partition 3, /dev/sda3 is the / (root) filesystem.

Here's how this boot scheme works:

  1. UEFI (contained in your motherboard's firmware) loads the Bootmanager entry from the RW NVRAM inside your motherboard.
  2. If there's a valid entry that contains Grub, then the GRUB boot loader code from your /boot filesystem will be loaded.
  3. UEFI can read from vfat partitions directly, which is why we use vfat instead of the normal ext2 for /boot.

Now, the boot loader is able to run and load the Linux kernel and initramfs from the vfat /boot filesystem, and start Funtoo Linux.

Pure UEFI

A Pure UEFI boot is also possible. The partitioning scheme is the same as the UEFI + GRUB scheme, above. This boot method is documented in detail in our Pure UEFI Boot Guide.

Here's how this boot scheme works:

  1. UEFI (contained in your motherboard's firmware) loads the Bootmanager entry from the RW NVRAM inside your motherboard.
  2. UEFI loads the Linux kernel STUB and initramfs directly, and runs the Linux kernel to start Funtoo Linux.