OS not booting on legacy mode UEFI machines

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
interruption
Posts: 22
Joined: Wed Feb 08, 2017 7:51 pm

OS not booting on legacy mode UEFI machines

Post by interruption »

Hi.

So I have a MBR bootloader that is defined as such:

Code: Select all

(510 bytes of code)
dw 55AAH
(more code)
This works for machines that do not have UEFI support entirely.
But machines that support UEFI (I have two of them, one is older than the other), they can't boot off of my imaged usb drive.
I am confused as to why this is happening. Should I have a FAT header before my code?
Does anyone know why this is happening?

thanks
User avatar
zaval
Member
Member
Posts: 659
Joined: Fri Feb 17, 2017 4:01 pm
Location: Ukraine, Bachmut
Contact:

Re: OS not booting on legacy mode UEFI machines

Post by zaval »

5.2.1 Legacy Master Boot Record (MBR)
A legacy MBR may be located at LBA 0 (i.e., the first logical block) of the disk if it is not using the
GPT disk layout (i.e., if it is using the MBR disk layout). The boot code on the MBR is not executed
by UEFI firmware.
But in your case, that even is not a valid MBR.
ANT - NT-like OS for x64 and arm64.
efify - UEFI for a couple of boards (mips and arm). suspended due to lost of all the target park boards (russians destroyed our town).
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: OS not booting on legacy mode UEFI machines

Post by Brendan »

Hi,
interruption wrote:So I have a MBR bootloader that is defined as such:

Code: Select all

(510 bytes of code)
dw 55AAH
(more code)
There's multiple problems with booting from USB flash, so I thought I'd start a "Problems Booting From USB Flash" page in the wiki. :)


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Octocontrabass
Member
Member
Posts: 5586
Joined: Mon Mar 25, 2013 7:01 pm

Re: OS not booting on legacy mode UEFI machines

Post by Octocontrabass »

Brendan wrote:There's multiple problems with booting from USB flash, so I thought I'd start a "Problems Booting From USB Flash" page in the wiki. :)
Looks good! One thing bothers me though.
Some firmware vendors have decided that USB flash devices should also be able to emulate CD, and support the El Torito specification for USB flash devices.
Do you have any proof for this statement?
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: OS not booting on legacy mode UEFI machines

Post by Brendan »

Hi,
Octocontrabass wrote:
Some firmware vendors have decided that USB flash devices should also be able to emulate CD, and support the El Torito specification for USB flash devices.
Do you have any proof for this statement?
I don't have proof and can't remember where I saw it mentioned. I may have got this around the wrong way (some USB flash devices emulate USB CD devices).


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Octocontrabass
Member
Member
Posts: 5586
Joined: Mon Mar 25, 2013 7:01 pm

Re: OS not booting on legacy mode UEFI machines

Post by Octocontrabass »

I've only ever heard of hybrid ISOs being bootable when written to a USB flash drive. I think the statement on El Torito in the article should be removed until someone can make a more compelling argument.
MichaelPetch
Member
Member
Posts: 799
Joined: Fri Aug 26, 2016 1:41 pm
Libera.chat IRC: mpetch

Re: OS not booting on legacy mode UEFI machines

Post by MichaelPetch »

interruption wrote:

Code: Select all

(510 bytes of code)
dw 55AAH
(more code)
This is only an addendum to the other answers regarding booting USB media. But the first thing that struck me is that your boot signature is incorrect. Expressed as a word the boot signature is actually dw 0AA55h or two individual bytes db 55h, 0AAh
Post Reply