[syslinux] Loading syslinux from a USB HDD

Josh Lehan jlehan at scyld.com
Thu Oct 19 12:55:11 PDT 2006


P.J. Dickson wrote:
> Thanks Nazo, for that amazing long answer.
> 
> The problem is, though, that you're talking to an _XP user_, so I 
> can't:  "Just use dd with
> if=/dev/sda"  because that's Dutch to me.  I even had trouble 
> understanding what a "distro" was, till I looked it up.  And I can't run 
> "mkdiskimage", because it doesn't run under XP.  Also, according to 
> Josh's post at http://www.knoppix.net/wiki/Bootable_USB_Key mkdiskimage 
> can't format over 1GB (if I understood correctly).

It's a limitation of the USB-ZIP "standard".  The disk geometry sizes 
are forced, to 32 sectors and 64 heads.  At 512 bytes per sector, that 
gives a total of 1MB per cylinder.  With the 1024 cylinder limit of 
traditional cylinder/head/sector (CHS) booting, that's 1GB.

There's only 2 solutions:

1) Format your USB key with a different size.

If you are forced to use traditional CHS booting, you can go up to 8GB. 
  The maximum is 1024 cylinders, 63 sectors, and 255 heads, which 
multiplies out to just a hair under 8GB.  (There's long stories about 
why it's 63 sectors and not 64, and also 255 heads and not 256, but I 
digress.)

This breaks the USB-ZIP "standard", though.  You're probably better off 
just using USB-HDD.

2) Use more than one partition.

Have a 1GB partition for booting, and another partition for your data.

Unfortunately, the USB-ZIP "standard" requires that the booting 
partition be the fourth partition.  Your data partition will have to 
appear earlier in the partition table, as one of the first three partitions.

However, the booting partition must appear at the beginning of the disk! 
  So, you will end up having a partition that is earlier in the table, 
but later on the disk.  You will have a partition table that is rather 
out of sequence.

Some fdisk-like partitioning programs might not like this, but I know of 
no other way.

I'd probably just end up blowing off any hope of USB-ZIP compatibility, 
and format the USB key with LBA partitions, where CHS sizes are not as 
relevant.  It wouldn't work on as many BIOS's, but of those that it can 
successfully work on, it would certainly be easier to use.

> OK, you both say it's basically easy, and I believe it is... for Linux 
> users.  The problem is that I don't speak Linux.  Us PC'ers are spoiled 
> by installers!  We just want to plug it in, click an exe, answer a 
> couple of questions and go get another cup of coffee... leastways that's 
> how I am.

Here's the recommended program for Windows users:

http://h18000.www1.hp.com/support/files/serveroptions/us/locate/69_6073.html

It's branded by HP, but it works on any standard USB key, regardless of 
vendor.

"Click an exe and answer a couple of questions" = If it works, you will 
successfully get the equivalent of a very large Windows bootable floppy. 
  The HP program automatically takes care of partitioning, formatting, 
and copying over certain Windows system files.

It's good enough to get a command prompt.  Unfortunately, running a full 
Windows installation, with graphics, is something that is very hard to 
do, without doing a full install.  Might want to look at BartPE.

http://www.nu2.nu/pebuilder/

Unfortunately, BartPE only works for a bootable CD/DVD.  Getting BartPE 
running on a bootable USB key would be a worthy project indeed!

Josh




More information about the Syslinux mailing list