After successfully installing and using Haiku on my old Be machine I got fixed and wanted to try it on my current box.
Using the same image (haiku-nightly-hrev49409-x86_gcc2_hybrid-anyboot) from an USB flash drive the system boots up fine. But my hard drive installation does not boot, so any tips are welcome.
What I have is an i7 4790 on an Gigabyte z97 based UEFI board. Attached are 4 SATA drives, port 0 & 1 are Intel SSDs for the OS, port 2 is a 3TB HDD for data and port 3 now features a 320GB hard disk I had lying around which I wanted to use for Haiku.
I tried both MBR and GUID schemes on the disk, and always used two partitions, one BFS and one FAT32 for data exchange. Installation went always fine, but selecting the drive for booting does not work.
If I use GUID scheme the disk is not selectable for booting in the BIOS. I also tried “Clover UEFI” boot loader but the Haiku partition won’t show up.
With MBR scheme the Haiku boot partition is shown (in BIOS as well as in Clover) but results in an error “insert boot media” (something like this).
Trying to boot from flash will always result in the flash disk being used for boot, since no matter how hard I try I can’t get into the boot menu with shift and or space (USB keyboard only).
Mounting the hard disk installation also shows that below the system folder there is no “kernel” or “boot loader” file. Is this correct?
Can I modify the flash disk so that it tries to boot from HDD first or that always the menu pops up before boot?
Having no kernel/bootloader file in the system folder is expected. The boot loader is stored in the first sectors of the partition, and the kernel is inside the Haiku package. The boot loader will load it from inside the package.
Make sure you have a valid MBR on your disk and that the partition you installed Haiku on is active. From inside Haiku you can use either a simple mbr, which you can write using the "writembr" command, or a more complete boot manager (with a menu allowing to boot several partitions), using the "bootman" command. You can of course use other boot loaders. The default MBR written by most tools should be fine (fdisk, etc), or you can also use Smart Boot Manager or some other similar tool.
If you create the partition you install Haiku to using DriveSetup, you have to mark it as active by checking the appropriate checkbox when creating it. If you don't do this, the MBR will not find the partition and the system will fail to boot.
Thanks PulkoMandy for your help.
writembr was the missing command. I thought that the makeboot command (the one which is also available in the tools menu of the Installer) was enough to get things going. Maybe adding writembr to the tools menu or context menu would be a nice idea :-).
Now I am able to select Haiku from the BIOS boot menu and successfully boot.
Regarding the kernel thing. So mounting a Haiku image will always show a somewhat empty volume, because everything is inside the packages and handled there? Can you give me a link to an explanation/doc whatever regarding this?
Regarding writembr: there are two steps to the boot process of x86 PC. The BIOS first loads the MBR (Master Boot Record) of the disk, which is located in the first sector just before the partition table. Then the MBR loads the active partition PBR (partition boot record) and runs it. Makebootable only writes the PBR. The MBR is set up by DriveSetup or whichever tool you used to write the partition table. Some tools will put there a “disabled” MBR which will only complain that the disk is not bootable or something similar. We don’t automatically overwrite it because that could prevent booting some other operating systems (some perform a check of the MBR to make sure there isn’t a virus installed there, and will abort boot if they see something unusual).
Regarding the package system, there is some written documentation, for example in the developer wiki (https://dev.haiku-os.org/wiki/PackageManagement) and in blog posts from several Haiku developers (https://www.haiku-os.org/tags/package_management?page=3). The developer wiki has a link to a youtube video of a talk by two developers explaining most of it.