Showing posts with label GRUB. Show all posts
Showing posts with label GRUB. Show all posts

2012-12-21

HOWTO: boot from a USB drive without BIOS support (using Plop Boot Manager & GRUB 2)

Plop Boot Manager is a freeware featureful x86 boot manager which can be executed from different media (e. g., HDD, CD / DVD, FDD, network, PCI option ROM). It can be loaded by BIOS or by another bootloader (LILO, GRUB, Syslinux etc.). It also has a (unique?) USB drive boot feature with no BIOS support requirement (note: PlopBoot's USB driver currenly provides exclusively a read-only DOS USB drive access).

In case you've installed some GNU / Linux distribution with GRUB 2 bootloader, here is a quick example of how to boot from USB drive using Plop Boot Manager started from GRUB 2:
  1. download the current version of Plop Boot Manager, extract the plpbt.bin file from the archive and put it into the /var/tmp/ folder (you can remove that file later when it's not needed anymore; no admin / root / superuser permissions needed to access this temp folder);
  2. reboot and wait for the GRUB menu interface to appear;
  3. press the 'c' key to enter the command-line interface (CLI) of GRUB:
    grub> _
  4. in case /var/tmp/ is not located on the boot / root partition, but, for example, on the 2nd partition of the 1st HDD, you should start with this GRUB CLI command:
    set root=(hd0,2)
  5. load the PlopBoot itself:
    linux16 /var/tmp/plpbt.bin
    boot
  6. after the Plop Boot Manager has been executed, you can select 'USB' from its menu to boot from your USB drive.
You can also permanently put Plop Boot Manager into the GRUB 2 boot menu (please read the appropriate section of the Plop Boot Manager documentation).
---
Last updated: 2014-06-10

2012-07-29

HOWTO: GRUB 2 rescue mode

Sometimes (e. g., after some disk re-partitioning) your GRUB 2 installation may get corrupted, so after the power-on you get only a "grub rescue> _" command prompt.
In such cases you'll need to know which disk partitions Linux & GRUB are installed on. In our example, it's 'sda7' (the 7th partition of the 1st HDD).

Type the following commands into the GRUB rescue prompt:
set root=(hd0,7)
set prefix=/boot/grub
insmod linux
linux /vmlinuz root=/dev/sda7 ro
initrd /initrd.img
boot
Notes:
  1. instead of '(hd0,7)', '(hd0,msdos7)' can be used for root;
  2. an alternative prefix is '(hd0,7)/boot/grub';
  3. an alternative insmod command argument path is '(hd0,7)/boot/grub/linux.mod'.
After successfully booting your GNU/Linux system, you should repair your GRUB 2 installation (execute these command as root, use su, or even better, sudo):
# grub-install /dev/sda
# update-grub2
Note: some people like to execute not update-grub2, but update-grub or even grub-mkconfig.

On the next reboot, it should work fine.

Some more useful GRUB2 reading:
  1. GNU GRUB Manual
  2. GRUB2 - ArchWiki
  3. Grub2 - Debian Wiki
  4. Grub2 - Community Ubuntu Documentation
  5. How To Fix GRUB 2 [Linux] ~ Web Upd8: Ubuntu / Linux blog
  6. linux - Making "default saved" work with GRUB2...? - Super User
---
Last updated: 2013-08-31