Saturday, March 8, 2008

The PC booting process

A certain mjvines had this explanation as a comment in his bootsector tutorial example. Thanks to him.. Just pasting it here lest I forget at a later point in time.

; Here's a quick summary of what the BIOS does when booting up.
; 1) Loads Sector 1, Track 0, Head 0 of the boot drive( A or C ) to
; absolute address 07C00h-07DFFh
; 2) Checks the 16 bit word at absolute address 07DFEh for AA55h. This is
; the boot signature and is used by the BIOS to ensure that the sector
; contains a value bootsector.
; If this signature isn't present, the BIOS will display a message like
; "Operating System Not Found"
; 4) Loads DL with
; 00h if the boot sector was loaded from drive A,
; 80h if the boot sector was loaded from drive C
; This way, the bootsector can determine which drive it was booted from.
; 5) Jumps to 0000:7C00h, which is the start of the bootsector


And on top of that, remember reading somewhere.. A CD boot is done by actually having a floppy image at the beginning of the cd.. This floppy image is loaded as a ramdisk and the ramdisk is used for the booting.. Can't remember the reference nor the exact details off the top of my head right now :(
Update: Found one reference now

While still on bootloaders, a good tutorial on using grub by Christopher Giese.


No comments: