All right ..
Reformulating my question:
I have problem with the number of partition entry in a bootloader.
VMware return 0x0:0x7CE (ds:si) in a second partition.
VirtualBox return 0x0:0x7BE (ds:si) in a first partition.
As you can see the values are not expected or not I'm interpreting well.
I expected 0x1BE in first partition and 0x1CE in second partition.
Please help me.
References:
http://wiki.osdev.org/MBR_(x86)
http://wiki.osdev.org/Partition_Table
PD. Sorry for my very bad english. I'm not kidding..
Invalid partition entry number (another question)
Re: Invalid partition entry number (another question)
What do you mean "return". What code returns these values?
-
- Member
- Posts: 5590
- Joined: Mon Mar 25, 2013 7:01 pm
Re: Invalid partition entry number (another question)
This is your problem.lweb20 wrote:or not I'm interpreting well
When this article says "offset 0x1be, 0x1ce, 0x1de, and 0x1ee", it is referring to the offset relative to the start of the MBR.
Re: Invalid partition entry number (another question)
Thanks for the responses.
At booting VMWare and VirtualBox have these values in "ds:si".iansjack wrote:What do you mean "return". What code returns these values?
MBR starting in 0x0 (sector zero) right? then relative offset are 0x1BE, ... right? if not, I don't understand.Octocontrabass wrote:When this article says "offset 0x1be, 0x1ce, 0x1de, and 0x1ee", it is referring to the offset relative to the start of the MBR.
Re: Invalid partition entry number (another question)
lweb20 wrote: MBR starting in 0x0 (sector zero) right? then relative offset are 0x1BE, ... right? if not, I don't understand.
Yes, the MBR is located in sector 0 of the disk. However, the article is talking about the location of the MBR in memory, after it's relocated itself to 0x0000:0x0600. 0x0600 + 0x01be = 0x07be, and so on.http://wiki.osdev.org/MBR_(x86) wrote:The MBR that FDISK uses is coded to:
- relocate itself to 0x0000:0x0600
- examine the byte at offset 0x1be, 0x1ce, 0x1de, and 0x1ee to determine the active partition
Those who understand Unix are doomed to copy it, poorly.
Re: Invalid partition entry number (another question)
Ahh how silly of me. I thought it was the offset on the disk, but it was in the memory. Thank you very much friend. Thank you so much.Minoto wrote:lweb20 wrote: MBR starting in 0x0 (sector zero) right? then relative offset are 0x1BE, ... right? if not, I don't understand.Yes, the MBR is located in sector 0 of the disk. However, the article is talking about the location of the MBR in memory, after it's relocated itself to 0x0000:0x0600. 0x0600 + 0x01be = 0x07be, and so on.http://wiki.osdev.org/MBR_(x86) wrote:The MBR that FDISK uses is coded to:
- relocate itself to 0x0000:0x0600
- examine the byte at offset 0x1be, 0x1ce, 0x1de, and 0x1ee to determine the active partition