Some tips to (re)install grub on an HP ProLiant server

HP Logo Yesterday I needed to fix the MBR of a ProLiant (Red Hat Enterprise
Linux 2.1) by reinstalling grub and grub-install just won’t work.
grub-install assumes that the boot device is in the form /dev/hda or
/dev/sda and since most ProLiant use a SmartArray RAID controller its
boot device is typically /dev/cciss/c0d0.

So, in order to recover this is what I did:

* In /etc/grub.conf (a link to /boot/grub/grub.conf) uncomment the
line that looks like this:

     boot=/dev/cciss/c0d0
     

* Make sure /boot/grub/device.map is setup right and looks like this:

        (fd0)     /dev/fd0
        (hd0)     /dev/cciss/c0d0
     

* Run grub like this:

   /sbin/grub --batch --device-map=/boot/grub/device.map
        --config-file=/boot/grub/grub.conf --no-floppy
   grub> root (hd0,0)
   grub> setup (hd0)
   grub> quit
  

Hope that helps!

Tags: ,

20 Responses to “Some tips to (re)install grub on an HP ProLiant server”

  1. Tom Baldridge Says:

    Thanks for the tip! It really saved my bacon with a new install of Fedora Core 3/64-bit on a dl585 with Smart Array 5i controller. Grub was not properly configured after the initial install and had to be recovered using your procedure.

  2. Petr Baudis Says:

    Same here. Fedora misconfigured Grub during install, you just saved me from hours of debugging this over those extra-long boot times… Thanks! ;-)

  3. Carlos Vidal Says:

    Same here too!! Feb 2005, installing Fedora Core 3 on a brand new ProLiant with Smart Array :-)

  4. Wang Ye Says:

    Thanks for the tips. It really helps. :)

  5. Keith Roberts Says:

    really appreciated

  6. Satheesh Prabu Says:

    Thanks a tone. It saved lot of my time.

  7. Brad Reisner Says:

    Very appreciated; spent 2 hours trying everything before I stubled on this.

  8. Some poor admin Says:

    As previously stated, thanks a ton. The GRUB documentation is a little light on what do with SCSI arrays, I had to dig thru google for a good hour before finding your post… :-)

  9. Thanks buddy Says:

    Thanks for the tip, it was a life saver!

  10. Fred V Says:

    Thanks a lot. Helped me solved a REALLY big problem with one of our servers.
    Nearly saved my life too !

  11. Matias Breunig Says:

    Tank you… this install de grub but after boot it show this message:
    root (hd0,0)

    Filesystem type is ext2fs, partition type Ox83

    kernel (hd0,0)/kernel-genkernel-x86_64-2.6.14-gentoo-r2 root=/dev/ram0 ramdisk=8192 real_root=/dev/cciss/c0d0p3 init=linuxrc udev doscsi
    [ Linux -bzImage,setup=0×1e00,size=0×22688e]
    initrd (hd0,0)/initramfs-genkernel-x86_64-2.6.14-gentoo-r2

    [Linux-initrd@0xdfe8b000, 0×157141 bytes]

    error 28: select itemcannot fit into memory

    press any key to continue…

    I have an 2 x 3.2 Xeon x96_84 with 4 x 1Gb RAM and Smart Array (RAID 5)

  12. Marc Nozell Says:

    Matias,

    The line: “error 28: select item cannot fit into memory” is the error message you need to follow up on.
    I’d poke around your kernel configuration to make sure it can support that large memory.

    -marc

  13. Steve Says:

    Thanks, this tip was a lifesaver. I had EXACTLY the same problem and the fix worked perfectly.

    – Steve

  14. Morten Slott Hansen Says:

    I have the exact same problem - however I have still not found a solution. I have tried several initrd files and get the dreaded error 28 each and every time.

    What exactly is it that I need to change in the kernel ?

  15. John Baxendale Says:

    Thanks for this - dead handy and saved me lots of messing about!

  16. tonio Says:

    Thanks a lot, save my time too :)

  17. Simon Says:

    Thx a lot also saved me loads of time trying to install Grub on Gentoo with an HP ProLiant DL380 G5. I can’t belive that this bug has not been fixed.

    Cheers Simon

  18. JimmyV Says:

    There is an easier way where you don’t need to edit any files. This works great in a script, but can be done on the command line as well

    /sbin/grub –batch /dev/null 2>/dev/null
    device (hd0) /dev/cciss/c0d0
    root (hd0,0)
    setup (hd0)
    quit
    EOT

  19. JimmyV Says:

    Somehow not all of the first line showed up it should be

    /sbin/grub –batch /dev/null 2>/dev/null
    device (hd0) /dev/cciss/c0d0
    root (hd0,0)
    setup (hd0)
    quit
    EOT

  20. Daniel Says:

    Thanks. This was very helpful.

Leave a Reply