You don't provide a minimal complete verifiable example showing a bootloader and how you get it into a VDI. Is there any way to solve this? Why is my virtual disk still not bootable? Edit So, I suppose it now means that the disk is bootable (because at the end of first sector is still signature 55 AA). Then, I basically filled from that address to the end of VDI file with pattern 55 AA. So, I found that data starts at some address (in my case it is 0x00200000 from the start of the VDI file). So, the start of VDI represents a header and the the rest is actual data stored on virtual drive. I was researching how VDI works and I found that it is usually dinamically allocated and that only the beginning of data is stored. So, I decided to put the binary machine code of my OS to virtual hard drive ( VDI file) and then set it to the top of boot order and load it instead of loading from virtual optical drive ISO. I don't want to convert my binary file to ISO every time. So, that is a lot of work I want to avoid.
I found that I must compile C code to binary format, extract text section and save it as a file, then convert it to ISO, then mount it to virtual optical dive of diskete and then load my OS in VirtualBox. I am creating an operating system in assembler and C. I read all of them, but none of them answers my problem. Step 1: Right click on the virtual machine that isn’t a bootable state and click on settings.There are a lot of question on stackoverflow with the similar title. If you are not sure which of the 2 reasons apply to you, I can show you a solution that covers both, and finally stop receiving the error message. VirtualBox works without any problems when a SATA storage device points to a virtual hard drive, but this is not the case for a bootable iso. Another issue can be appeared, if you mount accidentally the bootable iso to a SATA storage device controller instead of IDE.
There are two main reasons behind this issue: What causes this “Could not read from the boot medium” error? Note: This problem has to do purely with VirtualBox, and can be experienced on any host operating system be it Windows, Mac OS or Linux. This error is more common when trying to start a new virtual machine, but it is not impossible to happen at an existing virtual machine if the virtual hard drive is missing. Many VirtualBox users have experienced at least once the message ‘FATAL: Could not read from the boot medium! System halted.‘ Sometimes it is also shown ‘ No Bootable Medium Found! System halted‘.