boot problem in linux

In dracut emergency shell:

Dracut offers a shell for interactive debugging in the event dracut fails to locate your root filesystem. To enable the shell:

  1. Add the boot parameter ''rd.shell'' to your bootloader configuration file (e.g. /etc/grub.conf)

rhgb = redhat graphical boot - This is a GUI mode booting screen with most of the information hidden while the user sees a rotating activity icon spining and brief information as to what the computer is doing.

quiet = hides the majority of boot messages before rhgb starts. These are supposed to make the common user more comfortable. They get alarmed about seeing the kernel and initializing messages, so they hide them for their comfort.

rd.shell=This will present a shell should dracut be unable to locate your root device

  1. Remove the boot arguments ''rhgb'' and ''quiet'' A sample /etc/grub.conf bootloader configuration file is listed below.

default=0

timeout=5

serial --unit=0 --speed=9600

terminal --timeout=5 serial console

title Fedora (2.6.29.5-191.fc11.x86_64)

root (hd0,0)

kernel /vmlinuz-2.6.29.5-191.fc11.x86_64 ro root=/dev/mapper/vg_uc1-lv_root console=tty0 rd.shell

initrd /dracut-2.6.29.5-191.fc11.x86_64.img

  1. If system boot fails, you will be dropped into a shell as seen in the example below.

    No root device found Dropping to debug shell. sh: can't access tty; job control turned off

  2. Use this shell prompt to gather the information requested above (see the section called “All bug reports”).

5.Accessing the root volume from the dracut shell From the dracut debug shell, you can manually perform the task of locating and preparing your root volume for boot. The required steps will depend on how your root volume is configured. Common scenarios include:

• A block device (e.g. /dev/sda7)

• A LVM logical volume (e.g. /dev/VolGroup00/LogVol00)

• An encrypted device (e.g. /dev/mapper/luks-4d5972ea-901c-4584-bd75-1da802417d83)

• A network attached device (e.g. netroot=iscsi:@192.168.0.4::3260::iqn.2009-02.org.fedoraproject:for.all)

6.The exact method for locating and preparing will vary. However, to continue with a successful boot, the objective is to locate your root volume and create a symlink /dev/root which points to the file system. For example, the following example demonstrates accessing and booting a root volume that is an encrypted LVM Logical volume.

Inspect your partitions using parted
  1. You recall that your root volume was a LVM logical volume. Scan and activate any logical volumes

lvm vgscan

lvm vgchange -ay

  1. You should see any logical volumes now using the command blkid:

    blkid

    /dev/sda1: UUID="3de247f3-5de4-4a44-afc5-1fe179750cf7" TYPE="ext4"

    /dev/sda2: UUID="Ek4dQw-cOtq-5MJu-OGRF-xz5k-O2l8-wdDj0I" TYPE="LVM2_member"

    /dev/mapper/linux-root: UUID="def0269e-424b-4752-acf3-1077bf96ad2c" TYPE="crypto_LUKS"

    /dev/mapper/linux-home: UUID="c69127c1-f153-4ea2-b58e-4cbfa9257c5e" TYPE="ext3"

    /dev/mapper/linux-swap: UUID="47b4d329-975c-4c08-b218-f9c9bf3635f1" TYPE="swap"

9.With the root volume available, you may continue booting the system by exiting the dracut shell

exit