Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a new box running Debian Squeeze. Grub is installed on /dev/sda, but when booting up I just get a blinking cursor, before the Grub menu. I can only boot to grub successfully when I choose boot options (during post) and select that specific drive! I have made sure the correct drive is set to boot first in the BIOS.

So Grub works, but the system won't boot to that drive automatically? Any ideas on what could cause this?

Drives sda/b/c are all 2TB (sda runs the system with b/c as raid device md0) with the following partitions:

$ cat /proc/partitions

major minor  #blocks  name
8        0 1953514584 sda
8        1        977 sda1
8        2    9765625 sda2
8        3    6445313 sda3
8        4 1937302627 sda4
8       32 1953514584 sdc
8       16 1953514584 sdb
9        0 1953513424 md0

but

# fdisk -l /dev/sda

gives

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sda: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1      243202  1953514583+  ee  GPT

Any insight into this strange behaviour would be greatly appreciated.

share|improve this question
    
You should have used the p command in gdisk instead of fdisk, there. Not that the contents of your partition table are likely to be relevant to your problem, which hinges more on things like which disc your firmware is saying is unit 0x80 at any given moment. –  JdeBP May 25 '11 at 11:42
    
Thanks @JdeBP. Could you elaborate further on the unit 0x80 bit? –  delta1 May 25 '11 at 12:03
1  
Firmwares number hard disc units 0x80, 0x81, 0x82, and so forth. Which numbers are assigned to which disc units can vary, though. In particular, it can vary whenever the firmware's boot option menu is used. Some firmwares will make the selected disc unit always unit 0x80; others don't change the unit number, but tell the boot loader that unit 0x81/0x82/whatever is the boot disc. These behaviours interact badly with boot loaders that don't adhere to the BIOS Boot Specification. For the behaviour that you describe, you really need to concentrate on the firmware numbering, not Linux's. –  JdeBP May 25 '11 at 12:28
    
Thanks! I guess I'll be looking at updating the BIOS then, and trying to figure out that numbering. –  delta1 May 25 '11 at 12:50

2 Answers 2

Chances are the BIOS isn't at fault, although it could be. I'd look at the /boot/grub/device.map file, which holds the mapping of BIOS to Linux identifiers. It could be that's set up incorrectly and is causing problems. It might be hard to figure out which drive is which, though, since you've presumably got three identical drives in your RAID array.

share|improve this answer
    
Thanks for the suggestion. I've already made a workaround by installing grub on another hdd, and pointing the BIOS to that drive initially. This gets around the problem, but interestingly I think the only difference between the two drives is the partition table. I'll investigate again later when I have some time, and let you know what the differences are if you'd like. Thanks again for the answer :) –  delta1 Jun 23 '11 at 9:31

You have a GPT partition table, which means that the Linux might be installed as EFI.

Theory: When you're trying to boot without invoking the menu, GRUB stage 0 can't find the next stage in the GPT sub partition. When booting with the boot menu, the BIOS invokes EFI and the boot is successful. Try looking for for an option to boot into EFI mode in the BIOS and see if that makes a difference.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.