All of lore.kernel.org
 help / color / mirror / Atom feed
* Trouble booting from a large USB hard drive
@ 2010-01-17  9:25 Daniel Richard G.
  2010-01-17 14:36 ` Isaac Dupree
  2010-01-18  1:21 ` Grégoire Sutre
  0 siblings, 2 replies; 10+ messages in thread
From: Daniel Richard G. @ 2010-01-17  9:25 UTC (permalink / raw)
  To: grub-devel

I recently installed Ubuntu Linux to a 500GB external hard drive, with GRUB2, 
and at first could not boot the system due to a GRUB "unknown filesystem" 
error. Resolving this problem led to some interesting revelations that I 
wanted to share here.

Initially, the hard drive in question was partitioned to have a large (>400GB) 
FAT32 partition at the beginning. Knowing that Windows would only mount the 
first partition when the drive was plugged in, I figured this was the way to 
make the USB drive usable as a data vehicle on non-Linux systems. After that 
partition came ones for swap, root, and /home.

After installing Ubuntu, and rebooting, I got the GRUB error. This was on an 
HP laptop; later on, I connected the same drive to a Dell desktop 
machine---and lo, Ubuntu booted!

I believe that the cause of the problem with the HP laptop was a good 
ol'-fashioned BIOS barrier (a la "don't put /boot more than 8.4GB/33GB/137GB 
from the start of the disk"). The laptop was a fairly recent model---an HP 
EliteBook 6930p---but I'm guessing the code to boot from USB devices didn't 
have all the LBA workarounds and whatnot that have been standard in IDE/SATA 
boot code for years.

What all but confirmed it for me was an ingenious solution I saw posted 
somewhere: an out-of-order partition table. Put the Linux partitions first on 
the disk, then the big FAT32 partition---but the FAT32 partition is /dev/sdx1, 
and the Linux partitions are /dev/sdx{2,3,4}. Windows mounts the FAT32 
partition and ignores the others, just as intended, and Ubuntu boots 
flawlessly on the HP laptop.

Aside: All this is also covered in a GRUB bug report at

    https://savannah.gnu.org/bugs/?27069


With all that said, I don't consider this to be a bug in GRUB, and this is not 
meant to be taken as a bug report. (I presume grub-pc can't work around such 
limitations in the BIOS, because there isn't enough room in the MBR to stuff 
in a disk-reading library that makes BIOS disk calls unnecessary.) Rather, I 
think it is a corner case of which users should be aware---and perhaps GRUB 
and/or the Ubuntu installer could do a better job of warning the user if the 
disk layout may lead to that. Beyond that, broader awareness/support/use of 
out-of-order partition tables [for large USB drives in similar usage 
scenarios] doesn't seem like a bad idea.

(Which is not to say I'm certain of all this; that it's a BIOS barrier issue 
is only my hypothesis, consistent with what I've observed. Folks here might be 
aware of something else that may have been going on.)


--Daniel


-- 
Daniel Richard G. || danielg@teragram.com || Software Developer
Teragram Linguistic Technologies (a division of SAS)
http://www.teragram.com/





^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2010-01-18 18:16 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-17  9:25 Trouble booting from a large USB hard drive Daniel Richard G.
2010-01-17 14:36 ` Isaac Dupree
2010-01-17 20:45   ` Daniel Richard G.
2010-01-18  0:07     ` Colin Watson
2010-01-18  0:47       ` Isaac Dupree
2010-01-18  1:54       ` Daniel Richard G.
2010-01-18 12:38         ` Colin Watson
2010-01-18 18:15           ` Daniel Richard G.
2010-01-18  1:21 ` Grégoire Sutre
2010-01-18  2:10   ` Daniel Richard G.

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.