MAKING A GRUB BOOTABLE CD-ROM

xiaoxiao2021-03-06  40

MAKING A GRUB BOOTABLE CD-ROM

GRUB supports the no emulation mode in the El Torito specification1. This means that you can use the whole CD-ROM from GRUB and you do not have to make a floppy or hard disk image file, which can cause compatibility problems.

For booting from a CD-ROM, GRUB uses a special Stage 2 called stage2_eltorito. The only GRUB files you need to have in your bootable CD-ROM are this stage2_eltorito and optionally a config file menu.lst. You do not need to use Stage1 or Stage2, Because El Torito Is Quite Different from The Standard Boot Process.

Here is an esample of procedures to make a bootable CD-ROM Image. First, Make A Top Directory for the bootable Image, Say, ISO:

$ MKDIR ISO

Make A Directory for GRUB:

$ mkdir -p iso / boot / grub

Copy The File 2_ltorito:

$ CP / USR / Share / GRUB / I386-PC / Stage2_ltorito ISO / BOOT / GRUB

If Desired, Make The config file menu.lst under iso / boot / grub (see configuration), and Copy Any Files and Directories for the disc To the directory iso /.

Finally, make a iso9660 image file like this:

$ mkisofs -r -b boot / grub / stage2_ltorito -no-emul-boot /

-boot-loading-size 4 -boot-info-table -o grub.iso iso

This Products A File named Grub.iso, Which Ten Can Be Burned Into A CD (OR A DVD). Mkisofs Has Already Set Up Up / Grub / Stage2_ltrorito File, So There is no need to setup grub ON Note That the the bios on mix.).)

You can use the device (cd) to access a cd-rom in your config file. This is not required; grub automatically sets the root device to (cd) When booted from a cd-rom. It is only necessary to refer to Refer To CD) IF you want to access Other Drives as Well.

转载请注明原文地址:https://www.9cbs.com/read-53932.html

New Post(0)