6.2. Creating custom boot images
After you customize the boot images and the GUI layout, create a new image that includes the changes you made.
Procedure
-
Make sure that all of your changes are included in the working directory. For example, if you are testing an add-on, make sure to place the
product.imgin theimages/directory. -
Make sure your current working directory is the top-level directory of the extracted ISO image, for example,
/tmp/ISO/iso/. Install the following packages:
isomd5sum,xorriso,lorax:# dnf install isomd5sum xorriso loraxMake an EFI boot image by using
mkefiboot:# mkefiboot --label=ANACONDA /tmp/ISO/iso/EFI/BOOT/ /tmp/ISO/iso/images/efiboot.imgCreate a new ISO image by using the
xorrisofs:# xorrisofs -o ../NEWISO.iso -R -J -V RHEL-10-0-BaseOS-x86_64 --grub2-mbr /usr/lib/grub/i386-pc/boot_hybrid.img -partition_offset 16 -appended_part_as_gpt -append_partition 2 C12A7328-F81F-11D2-BA4B-00A0C93EC93B /tmp/ISO/iso/images/efiboot.img -iso_mbr_part_type EBD0A0A2-B9E5-4433-87C0-68B6B72699C7 -c boot.cat --boot-catalog-hide -b images/eltorito.img -no-emul-boot -boot-load-size 4 -boot-info-table --grub2-boot-info -eltorito-alt-boot -e --interval:appended_partition_2:all:: -no-emul-boot -graft-points .discinfo=/tmp/ISO/iso/.discinfo images/install.img=/tmp/ISO/iso/images/install.img images/pxeboot=/tmp/ISO/iso/images/pxeboot boot/grub2=/tmp/ISO/iso/boot/grub2 boot/grub2/i386-pc=/usr/lib/grub/i386-pc images/eltorito.img=/tmp/ISO/iso/images/eltorito.img EFI/BOOT=/tmp/ISO/iso/EFI/BOOTIn the above example:
Ensure the value for the
-Voption matches the image’s boot loader configuration, if you are using theLABEL=directive for options that require a location to load a file on the same disk. If your boot loader configuration (boot/grub2/grub.cfgfor BIOS andEFI/BOOT/grub.cfgfor UEFI) uses theinst.stage2=LABEL=disk_labelstanza to load the second stage of the installer from the same disk, then the disk labels must match.중요In boot loader configuration files, replace all spaces in disk labels with
\x20. For example, if you create an ISO image with aRHEL 10.0label, boot loader configuration should useRHEL\x2010.0.-
Replace the value of the
-ooption (-o ../NEWISO.iso) with the file name of your new image. The value in the example creates theNEWISO.isofile in the directory above the current one. For more information about this command, see thexorrisofs(1)man page on your system.
Implant an MD5 checksum into the image. Note that without an MD5 checksu, the image verification check might fail (the
rd.live.checkoption in the boot loader configuration) and the installation can hang.# implantisomd5 ../NEWISO.isoIn the above example, replace ../NEWISO.iso with the file name and the location of the ISO image that you have created in the previous step.
You can now write the new ISO image to physical media or a network server to boot it on physical hardware, or you can use it to start installing a virtual machine.