Linux – Repair Bootloader / Change Boot device path
If a Linux sever is not booting anymore (e.g. HP Proliant server) and on screen the following message appears:
“boot from hard drive c: no operating system”
there is usually a problem with boot disk device path, for example after changing configuration on Raid Controller or moving disks from one disk controller to another etc.
Solution
Boot into Rescue Mode
Just boot from a Linux Live CD/DVD (f.e. RHEL 6 installation DVD) an choose “Rescue Mode”, which gives you a root terminal after boot.
Mount disk devices
Mount all devices (including /dev device, otherwise you run into trouble later !)
Rescue# fdisk -l
Rescue# mount /dev/vg00/lv_root /mnt
Rescue# mount /dev/cciss/c0d0p1 /mnt/boot
Rescue# mount -o bind /dev /mnt/dev
Chroot into mounted Root environment
Rescue# chroot /mnt
Hint: If you get an error like “/bin/sh: exec format error” you use the wrong LiveCD (e.g. x86 instead of x86_64)
Run Grub CLI
Rescue# grub
grub> root (hd0, 0) -> hd0,0 is actually the first partition on first disk (e.g. /dev/cciss/c0d0p1, basically /boot partition)
grub> setup (hd0)
grub> quit
Change entries in /boot/grub/menu.lst
Last step is to set correct entries in bootloader config file.
vim /boot/grub/menu.lst
splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Enterprise Linux (2.6.32-220.el6.x86_64)
root (hd0,0)
Reboot Server
After the steps above you should be able to boot server again.
Rescue# reboot
1 Comment »
Leave a comment
-
Recent
- Linux – Repair Bootloader / Change Boot device path
- Join RedHat Linux to Microsoft Active Directory
- HP-UX Increase Veritas cluster filesystem (CFS) online
- MC/Serviceguard Cluster – Replace Quorum Server
- HP-UX Integrity Virtual Machines (Integrity VM)
- MC/Serviceguard Cluster on HP-UX 11.31
- HP-UX 11i comfortable shell environment
- Xen Guest (DomU) Installation
- Linux SAN Multipathing (HP Storage)
- Linux Network Bonding
- Linux SAN Multipathing
- ASM Disk not shown in Oracle Universal Installer (OUI) or DBCA
-
Links
-
Archives
- December 2011 (1)
- July 2010 (1)
- April 2010 (1)
- August 2009 (1)
- October 2008 (1)
- August 2008 (1)
- May 2008 (1)
- March 2008 (1)
- February 2008 (1)
- December 2007 (1)
- November 2007 (5)
-
Categories
-
RSS
Entries RSS
Comments RSS
Hi, Thomas. I have an ask regarding to HP-UX. Is it possible to contact you personally somehow (e.g. e-mail)? Thanks.
Comment by Alex | November 26, 2013 |