Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to debug a boot loader?

I debugged small programs using gdb.

I have source code of GRUB. Second stage of GRUB is written in C. Can I debug it using gdb ?

Is it possible to debug a boot loader ? If yes, then how ?

like image 312
Vikram Avatar asked Aug 30 '12 20:08

Vikram


People also ask

What is boot debug?

The /bootdebug boot option enables or disables boot debugging of the current or specified Windows operating system boot entry.

How do I debug Windows startup?

To enable boot debugging, use the BCDEdit /bootdebug command and specify the appropriate boot component. If you wish to perform kernel debugging after Windows starts, use the BCDEdit /debug command as well. You must also select a debugging connection, just as in normal kernel debugging.


1 Answers

  1. I would check out bochs
  2. You can also use gdb with bochs
  3. OSDev has a wealth of information on debugging a bootloader
like image 175
emsworth Avatar answered Oct 04 '22 20:10

emsworth