BootSector problem

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.
opc0de
Posts: 13
Joined: Wed Jun 08, 2011 1:53 am

Re: BootSector problem

Post by opc0de »

berkus wrote:You seem to be a little dissociative, so no thank you but no.
i don't know what is your problem ... can you make me a favour and ignore this thread you are to experienced for me...
User avatar
iocoder
Member
Member
Posts: 208
Joined: Sun Oct 18, 2009 5:47 pm
Libera.chat IRC: iocoder
Location: Alexandria, Egypt | Ottawa, Canada
Contact:

Re: BootSector problem

Post by iocoder »

Oh dear, you have erased partition table??????
User avatar
iocoder
Member
Member
Posts: 208
Joined: Sun Oct 18, 2009 5:47 pm
Libera.chat IRC: iocoder
Location: Alexandria, Egypt | Ottawa, Canada
Contact:

Re: BootSector problem

Post by iocoder »

opc0de: could you please send us the 512 binary image of your MBR and the 512 byte binary image of the original MBR??? I will edit your proggy MBR and add the partition table to it, then write it to sector 0 and your issue might be solved..
opc0de
Posts: 13
Joined: Wed Jun 08, 2011 1:53 am

Re: BootSector problem

Post by opc0de »

I have done it didn't knew that overwriting the partition table will stop the machine from booting since the actual MBR is restored in memory...Thanks all for your help and good luck with you projects.
User avatar
iocoder
Member
Member
Posts: 208
Joined: Sun Oct 18, 2009 5:47 pm
Libera.chat IRC: iocoder
Location: Alexandria, Egypt | Ottawa, Canada
Contact:

Re: BootSector problem

Post by iocoder »

I have done it didn't knew that overwriting the partition table will stop the machine from booting since the actual MBR is restored in memory...
NTLDR needs to know how your computer is partitioned, so it loads sector 0 [MBR] to memory and expects that it contains the partition table.
Thanks all for your help and good luck with you projects.
You are welcome :)

Regards,
Mostafa Abd El-Aziz
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: BootSector problem

Post by Brendan »

Hi,

"org" is used by the assembler to calculate the offset of labels (withing whatever segment), and what segment you're using makes no difference. For example, if the code is loaded at 0x0123:0x4567 then the "org" would be "0x4567". If the code is loaded at 0x1000:0x0000 then "org" would 0x0000.


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.
Post Reply