Tuesday, August 16, 2011

Working with GRUB, Recover MBR

The GRUB bootloader is broken down into different stages. The code contained on the master boot record (MBR) is considered GRUB stage 1. It loads GRUB stage 1.5, which tries to identify the file system type (optional), or it can call GRUB stage 2 directly. Stage 2 is what calls the kernel and loads it into memory. In stage 1, GRUB needs to search the MBR looking for an active partition from which to boot the kernel. Grub boot options: e Edit the commands before booting a Modify or append the kernel arguments before booting c Open the GRUB command line Recover broken MBR in GRUB Boot the machine andd wait until the GRUB message appears and hit c.
GNU GRUB version 0.97 (639K lower . 392128K upper memory) [ Minimal BASH-like line editing is supported. For the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device/filename. ESC at any time exits.] grub > find /grub/grub.conf (hd0,0) grub > root (hd0,0): Filesystem type is unknown, partition type 0x8e grub > setup (hd0) Checking if “/boot/grub/stage1” exists... no Checking if “/grub/stage1” exists... yes Checking if “/grub/stage2” exists... yes Checking if “/grub/e2fs_stage1_5” exists... yes Running “embed /grub/e2fs_stage1_5 (hd0)”... 26 sectors are embedded. succeeded. Running “install /grub/stage1 (hd0) (hd0)1+26 p(hd0,0)/grub/stage2 /grub/grub.conf”... succeeded Done. grub >

No comments:

Post a Comment

MABM

Demo: Create MBAM 2.5 users and groups in Active Directory Domain Services Configure MBAM 2.5 Roles for the instance of SQL Server ...