Changeset c8391c3d for postlfs/filesystems/uefi-bootloaders/grub-setup.xml
- Timestamp:
- 09/20/2022 03:45:30 AM (2 years ago)
- Branches:
- 11.3, 12.0, 12.1, 12.2, gimp3, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, xry111/for-12.3, xry111/llvm18, xry111/spidermonkey128, xry111/xf86-video-removal
- Children:
- 4afbfbd
- Parents:
- ea11b87
- git-author:
- Pierre Labastie <pierre.labastie@…> (09/20/2022 03:40:16 AM)
- git-committer:
- Pierre Labastie <pierre.labastie@…> (09/20/2022 03:45:30 AM)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
postlfs/filesystems/uefi-bootloaders/grub-setup.xml
rea11b87 rc8391c3d 20 20 <para> 21 21 BLFS does not have the essential packages to support Secure Boot. To 22 set up the boot process with GRUB for UEFI installedin BLFS, Secure22 set up the boot process with GRUB and UEFI in BLFS, Secure 23 23 Boot must be turned off from the configuration interface of the 24 24 firmware. Read the documentation provided by the manufacturer of your … … 99 99 100 100 <para> 101 Now the USB flash drive can be used as a emergency boot disk onx86-64101 Now the USB flash drive can be used as an emergency boot disk on any x86-64 102 102 UEFI platform. It will boot the system and show the GRUB shell. Then you 103 can type commands to boot your operating system s onthe hard drive.103 can type commands to boot your operating system from the hard drive. 104 104 To learn how to select the boot device, read the manual of your 105 105 motherboard or laptop. … … 142 142 143 143 <variablelist> 144 <title>The meaning of the configur eoptions:</title>144 <title>The meaning of the configuration options:</title> 145 145 146 146 <varlistentry> … … 172 172 <listitem> 173 173 <para>The combination of these options allows the kernel to 174 print debug messages (along with Tux logos) at theearly stage of175 the boot process with UEFI. To ensure the m functional at theearly176 stage, they shouldn't be built as a kernel moduleunless an174 print debug messages (along with Tux logos) at an early stage of 175 the boot process with UEFI. To ensure they are functional at that early 176 stage, they shouldn't be built as kernel modules unless an 177 177 initramfs will be used.</para> 178 178 </listitem> … … 187 187 188 188 <para> 189 On EFI based system , the bootloaders are installed in a special FAT32189 On EFI based systems, the bootloaders are installed in a special FAT32 190 190 partition called an <emphasis>EFI System Partition</emphasis> (ESP). 191 If your system supports EFI, and a recent version of Linux191 If your system supports EFI, and a recent version of some Linux 192 192 distribution or Windows is pre-installed, it's likely that the ESP 193 is alreadycreated. As the193 has already been created. As the 194 194 <systemitem class="username">root</systemitem> user, list all the 195 195 partitions on your hard drive (replace <userinput>sda</userinput> … … 205 205 206 206 <para> 207 If the system or the hard drive is new, or it's a first time208 install an UEFIbooted OS on the system, the ESP may not exist.207 If the system or the hard drive is new, or it's the first 208 installation of a UEFI-booted OS on the system, the ESP may not exist. 209 209 In that case, create a new partition, make a 210 210 <systemitem class="filesystem">vfat</systemitem> file system on it, … … 215 215 <warning> 216 216 <para> 217 Some (old) UEFI implementations may demandthe ESP to be the first217 Some (old) UEFI implementations may require the ESP to be the first 218 218 partition on the disk. 219 219 </para> … … 252 252 <filename>EFI/BOOT/BOOTX64.EFI</filename>. Normally, a boot loader 253 253 should be installed into a custom path and the path should be recorded 254 in tothe EFI variables. The use of the hardcoded path should be255 avoided as much aspossible. However, in some cases we have to use254 in the EFI variables. The use of the hardcoded path should be 255 avoided if possible. However, in some cases we have to use 256 256 the hardcoded path: 257 257 </para> … … 260 260 <listitem> 261 261 <para> 262 The system is not booted with EFI yet, causing EFI variables262 The system is not booted with EFI yet, making EFI variables 263 263 inaccessible. 264 264 </para> … … 266 266 <listitem> 267 267 <para> 268 The EFI firmware is 64-bit but the LFS system is 32-bit, causing268 The EFI firmware is 64-bit but the LFS system is 32-bit, making 269 269 EFI variables inaccessible because the kernel cannot invoke EFI 270 270 runtime services with a different virtual address length. … … 273 273 <listitem> 274 274 <para> 275 LFS is built for a Live USB, so we cannot rely on EFI variables 276 which isstored in NVRAM or EEPROM on the local machine.275 LFS is built for a Live USB, so we cannot rely on EFI variables, 276 which are stored in NVRAM or EEPROM on the local machine. 277 277 </para> 278 278 </listitem> 279 279 <listitem> 280 280 <para> 281 You are unable or unwilling to install 281 You are unable or unwilling to install the 282 282 <application>efibootmgr</application> for manipulating boot 283 283 entries in EFI variables. … … 287 287 288 288 <para> 289 In these cases, follow th is section to installGRUB EFI289 In these cases, follow these instructions to install the GRUB EFI 290 290 application into the hardcoded path and make a minimal boot 291 configuration. Otherwise it's better to skip this section and readthe292 remaining sections to set up the boot configuration in a normal way.293 </para> 294 295 <para> 296 To install GRUB with the EFI application in stalled intothe hardcoded291 configuration. Otherwise it's better to skip ahead and set up the 292 boot configuration normally. 293 </para> 294 295 <para> 296 To install GRUB with the EFI application in the hardcoded 297 297 path <filename>EFI/BOOT/BOOTX64.EFI</filename>, first ensure the boot 298 298 partition is mounted at <filename class="directory">/boot</filename> 299 and the ESP mounted at300 <filename class="directory">/boot/efi</filename>. Then as the &root;299 and the ESP is mounted at 300 <filename class="directory">/boot/efi</filename>. Then, as the &root; 301 301 user, run the command: 302 302 </para> … … 304 304 <note> 305 305 <para> 306 Th ecommand will overwrite306 This command will overwrite 307 307 <filename>/boot/efi/EFI/BOOT/BOOTX64.EFI</filename>. It may break a 308 308 bootloader already installed there. Back it up if you are not sure. … … 313 313 314 314 <para> 315 Th e command would installGRUB EFI application into the hardcoded path315 This command will install the GRUB EFI application into the hardcoded path 316 316 <filename>/boot/efi/EFI/BOOT/BOOTX64.EFI</filename>, so the EFI 317 317 firmware can find and load it. The remaining GRUB files are installed 318 in to<filename class="directory">/boot/grub</filename> directory and318 in the <filename class="directory">/boot/grub</filename> directory and 319 319 will be loaded by <filename>BOOTX64.EFI</filename> during system boot. 320 320 </para> … … 322 322 <note> 323 323 <para> 324 The EFI firmware usually prefers the EFI applications with thepath325 recorded in boot entries stored in EFI variables,to the EFI324 The EFI firmware usually prefers the EFI applications with a path 325 stored in EFI variables to the EFI 326 326 application at the hardcoded path. So you may need to invoke the 327 327 boot selection menu or firmware setting interface to select the 328 328 newly installed GRUB manually on the next boot. Read the manual of 329 your motherboard or laptop to figure outhow.329 your motherboard or laptop to learn how. 330 330 </para> 331 331 </note> 332 332 333 333 <para> 334 If you've followed th is section and set up a minimal boot335 configuration, now skip until334 If you've followed the instructions in this section and set up a minimal boot 335 configuration, now skip ahead to 336 336 <quote>Creating the GRUB Configuration File</quote>. 337 337 </para> … … 343 343 <para> 344 344 The installation of GRUB on a UEFI platform requires that the EFI Variable 345 file system, <systemitem class="filesystem">efivarfs</systemitem>, to be345 file system, <systemitem class="filesystem">efivarfs</systemitem>, is 346 346 mounted. As the <systemitem class="username">root</systemitem> user, 347 347 mount it if it's not already mounted: … … 354 354 If the system is booted with UEFI and systemd, 355 355 <systemitem class="filesystem">efivarfs</systemitem> will be mounted 356 automatically. However in the LFS chroot environment it still needs to356 automatically. However, in the LFS chroot environment it still needs to 357 357 be mounted manually. 358 358 </para> … … 375 375 <filename class="directory">/sys/firmware/efi</filename> will be 376 376 missing. In this case you should boot the system in UEFI mode with 377 the emergency boot disk or minimal boot configuration created as377 the emergency boot disk or using a minimal boot configuration created as 378 378 above, then mount 379 379 <systemitem class="filesystem">efivarfs</systemitem> and continue. … … 401 401 GRUB-2.06) so it will not use much space in the ESP. A typical ESP 402 402 size is 100 MB (for Windows boot manager, which uses about 50 MB in 403 the ESP). Once <filename>grubx64.efi</filename> loaded by the404 firmware, it will load GRUB modules inthe boot partition.403 the ESP). Once <filename>grubx64.efi</filename> has been loaded by the 404 firmware, it will load GRUB modules from the boot partition. 405 405 The default location is 406 406 <filename class="directory">/boot/grub</filename>. … … 424 424 425 425 <para> 426 Issue <command>efibootmgr | cut -f 1</command>to recheck the EFI boot426 Issue the <command>efibootmgr | cut -f 1</command> command to recheck the EFI boot 427 427 configuration. An example of the output is: 428 428 </para> … … 485 485 <para> 486 486 <literal>(hd0,2)</literal>, <literal>sda2</literal>, and 487 <literal>5.19.2-lfs-11.2</literal> should be replaced tomatch your487 <literal>5.19.2-lfs-11.2</literal> must match your 488 488 configuration. 489 489 </para> … … 491 491 <note> 492 492 <para> 493 From GRUB's perspective, the files are relative to the partition 494 areused. If you used a separate /boot partition, remove /boot from the493 From GRUB's perspective, the files are relative to the partitions 494 used. If you used a separate /boot partition, remove /boot from the 495 495 above paths (to kernel and to <filename>unicode.pf2</filename>). You 496 will also need to change the set rootline to point to the boot496 will also need to change the "set root" line to point to the boot 497 497 partition. 498 498 </para> … … 530 530 in this case the Windows Boot Manager. You may put more usable tools 531 531 in EFI executable format (for example, an EFI shell) into the ESP and 532 create GRUB entries for them .532 create GRUB entries for them, as well. 533 533 </para> 534 534
Note:
See TracChangeset
for help on using the changeset viewer.