I have neverf done a bootable USB drive before. Never really had a reason. Now I have done my first with Haiku. But I ahve to use a CD to make it boot If i put in the CD and hold sift, I can then select the USB and boot it. I am not sure what I am doing wrong. I created the USB using the installer in Haiku. It went just fineā¦???
David
1-does your USB-drive have a partition table ?
if not, it way be not recognized by the BIOS as a bootable drive
2-did you create the MBR with haiku ?
the master boot record should contain a little program, whose role is to load the boot sector of the partition.
How do I confirm if my USB has a partition table? If I use the CD (hold the shift) and manually choose the usb drive as the boot device it works.
The installer complted and gave a message that it has created a MBR on the USB drive.
Open DriveSetup
you will see something like
/dev/disk/USB/0/0/raw
=> itās your USB device.
if you have a partition table, you will see (just below your device
) something like
/dev/disk/USB/0/0/0
=> itās your partition
Installer doesnāt touch (or create) the MBR. However, it writes the haiku_loaderās address in the partitionās boot sector (also called āsuperblockā)
yes I have a partition
/dev/disk/USB/0/0/0
is there. I used gparted and made sure that the partition flag was ābootableā however I still donāt have a bootable usb drive.
It seems your MBR havenāt a working boot code.
here is a method to install a boot code on your USB drive.
Start DriveSetup to find the actual device_path for your CD (we are going to use the boot code from the Haiku CD becauseā¦ it works)
it could be something like : /dev/disk/atapi/0/slave/raw
(find the line with the CD icon)
Open Terminal and type the following command to install the MBR boot code from the CD to the USB drive (adapt the command, to your actual device_paths):
dd if=/dev/disk/atapi/0/slave/raw of=/dev/disk/USB/0/0/raw bs=440 count=1
if is your source device (the Haiku CD)
of is your target USB drive
bs is the size of the block to copy - in bytes (itās also the size of the boot code area). If you donāt want overwrite the partitions table, donāt exceed 440 bytes !
count is the number of block to copy
Now, you should be able to boot from the drive.
Have a lot of fun with Haiku!
edit:
This operation is done once for all, even if you install a new version.
I got it! Well sorta. It will boot on one PC, the one that is not really supported driver wise. But, doesnāt boot on the one that does have supported hardware. Either way, if I use the CD I can always choose to actually boot from the USB Drive. Thanks for all the help. Looking forward to seeing what happens next.