Bienvenido! - Willkommen! - Welcome!

Bitácora Técnica de Tux&Cía., Santa Cruz de la Sierra, BO
Bitácora Central: Tux&Cía.
Bitácora de Información Avanzada: Tux&Cía.-Información
May the source be with you!

Sunday, November 6, 2011

Invoking grub-install and grub-mkrescue

Source 
The program grub-install installs GRUB on your drive using grub-mkimage and (on some platforms) grub-setup. You must specify the device name on which you want to install GRUB, like this:
     grub-install install_device
The device name install_device is an OS device name or a GRUB device name.
grub-install accepts the following options:
--help
Print a summary of the command-line options and exit.
--version
Print the version number of GRUB and exit.
--boot-directory=dir
Install GRUB images under the directory dir/grub/ This option is useful when you want to install GRUB into a separate partition or a removable disk. If this option is not specified then it defaults to /boot, so
          grub-install /dev/sda
is equivalent to
          grub-install --boot-directory=/boot/ /dev/sda
Here is an example in which you have a separate boot partition which is mounted on /mnt/boot:
          grub-install --boot-directory=/mnt/boot /dev/sdb
--recheck
Recheck the device map, even if /boot/grub/device.map already exists. You should use this option whenever you add/remove a disk into/from your computer.
22 Invoking grub-mkrescue
The program grub-mkrescue generates a bootable GRUB rescue image (see Making a GRUB bootable CD-ROM).
     grub-mkrescue -o grub.iso
All arguments not explicitly listed as grub-mkrescue options are passed on directly to xorriso in mkisofs emulation mode. Options passed to xorriso will normally be interpreted as mkisofs options; if the option ‘--’ is used, then anything after that will be interpreted as native xorriso options.
Non-option arguments specify additional source directories. This is commonly used to add extra files to the image:
     mkdir -p disk/boot/grub
     (add extra files to disk/boot/grub)
     grub-mkrescue -o grub.iso disk
grub-mkrescue accepts the following options:
--help
Print a summary of the command-line options and exit.
--version
Print the version number of GRUB and exit.
-o file
--output=file
Save output in file. This "option" is required.
--modules=modules
Pre-load the named GRUB modules in the image. Multiple entries in modules should be separated by whitespace (so you will probably need to quote this for your shell).
--rom-directory=dir
If generating images for the QEMU or Coreboot platforms, copy the resulting qemu.img or coreboot.elf files respectively to the dir directory as well as including them in the image.
--xorriso=file
Use file as the xorriso program, rather than the built-in default.
--grub-mkimage=file
Use file as the grub-mkimage program, rather than the built-in default.

No comments: