Page 1 of 1

GRUB crashing

Posted: Sun Nov 11, 2012 6:25 pm
by mich
Hi,

I have one old computer, which I thought I could use as a development box. However, I found that GRUB (both 0.97 and 1.98) crashes on it.

GRUB's boot prompt and console come up fine but when loading any OS, even a simple "L0; cli; hlt; jmp L0;" causes a reset (presumably even before the OS is reached). It doesn't even matter what GRUB is trying to load. Same boot device, however, works on other hardware (and software emulators).

Other bootup code and bootloaders work fine on the offending machine. But these are not as powerful and comfortable as GRUB or any other Multiboot bootloader for that matter.

Has anyone else had similar experience? Is there a workaround? Any other good free open source Multiboot compliant bootloaders?

Thank you for your attention.

EDIT: It is a Fujitsu Siemens Scenic D i845g system with an yet to be identified P4 CPU.

Re: GRUB crashing

Posted: Sun Nov 11, 2012 6:53 pm
by linguofreak
Exactly how old is the machine?

Re: GRUB crashing

Posted: Sun Nov 11, 2012 7:47 pm
by gerryg400
I have a 3 yr old machine on which Grub 0.96 doesn't work.

Re: GRUB crashing

Posted: Mon Nov 12, 2012 2:19 am
by mich
linguofreak wrote:Exactly how old is the machine?
I forgot to mention that it is a Fujitsu Siemens Scenic D i845g system with an yet to be identified P4 CPU. So its from 2002 ... 2004.

Re: GRUB crashing

Posted: Mon Nov 12, 2012 3:00 am
by mich
pitfall wrote:I guess your hardware has a watchdog timer. This produces a hardware reset when entering halt state with IF cleared. I got the same problem with an old dell.
No. I don't think so, because (and correct me if I'm wrong)

Code: Select all

boot:
	cli ; works with out cli as well
	hlt ; also without hlt
	jmp boot ; also with only this jmp

	times 510-($-$$) db 0
	db 0x55
	db 0xaa
works fine.
Or does the watchdog timer only manifest when in Protected Mode or some other setup has been performed?

The problem really seems to be that GRUB has not even come to the point where it hands over control to my system when the PC resets.

Anyway I will try to build the latest version of GRUB and test with that.

This is really frustrating. All I want to do is OS development and not constantly mess with unrelated hardware/software problems ... Is this the point where I should roll my own boot loader? :P

Re: GRUB crashing

Posted: Mon Nov 12, 2012 3:29 am
by bluemoon
mich wrote:Is this the point where I should roll my own boot loader? :P
If that sound interesting for you, go ahead; just define the boot sequence and interface properly so that you can always go back for GRUB or other "complete boot loader"

Re: GRUB crashing

Posted: Mon Nov 12, 2012 7:42 pm
by BMW
mich wrote:Is this the point where I should roll my own boot loader? :P
I say go for it. It's not hard.

Re: GRUB crashing

Posted: Tue Nov 13, 2012 8:10 am
by neon
Hello,
BMW wrote:
mich wrote:Is this the point where I should roll my own boot loader? :P
I say go for it. It's not hard.
Not entirely true. Boot loaders can get complicated and large depending on the design goals. GrUB is one such example. Of course, its relatively easy to write a simple VBR to parse and execute a file, but that's hardly a boot loader.

Unfortunately I don't use GrUB so cannot address the original posters questions. If you do decide to write your own boot loader, I encourage following Bluemoon's advice above.