Bochs and Grub

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

Bochs and Grub

Post by spider »

Im trying to get bochs to load my kernel from my hdd. I dont want to place this kernel in the mbr or anything. I currently have grub installed on my system to boot into linux. And my kernel (kernel.bin) is located on my linux partition. I was wondering if there is anyway to get bochs or qemu it doesnt bother me which one to load my current installation of grub (i can then just config grub to load my kernel) or to get bochs/qemu to just load my kernel straight from my hdd. I should note im not using my own bootloader(which is why i was more leaning to using my current installation of grub as my bootloader).
bluecode

Re:Bochs and Grub

Post by bluecode »

spider wrote:Im trying to get bochs to load my kernel from my hdd. I dont want to place this kernel in the mbr or anything.
Why don't you just configure grub (/boot/grub/menu.lst), reboot your system and let grub boot your kernel... ???
or to get bochs/qemu to just load my kernel straight from my hdd.
Tell bochs/qemu to use /dev/hdXY as your hdd image.

Or am I completely missing the point?
spider

Re:Bochs and Grub

Post by spider »

bluecode wrote: Why don't you just configure grub (/boot/grub/menu.lst), reboot your system and let grub boot your kernel... ???
I thought about doing that, but that would be a pain in the @$$ having to restart my computer everytime i want to test the kernel.
or to get bochs/qemu to just load my kernel straight from my hdd.
Tell bochs/qemu to use /dev/hdXY as your hdd image.

Or am I completely missing the point?
Nope your not missing anything. I was playing around with bochs for a few hours last night and it keept erroring out on me, i thought i tryed that. Ill try it again. Thanx.
spider

Re:Bochs and Grub

Post by spider »

when ever i try to open /dev/hdXY in qemu it just tells me it cant open the hard disk image
bluecode

Re:Bochs and Grub

Post by bluecode »

You must be root to use files in /dev/.
spider

Re:Bochs and Grub

Post by spider »

my bad, it works now kind of. Grub just gives me error 21. OH well i downloaded an image file off the net that has grub on it and that loads perfect for me.
evincarofautumn

Re:Bochs and Grub

Post by evincarofautumn »

I thought about doing that, but that would be a pain in the @$$ having to restart my computer everytime i want to test the kernel.
Not to mention the fact that it may decrease its lifespan.
Tell bochs/qemu to use /dev/hdXY as your hdd image.
"...this is NOT RECOMMENDED" by the makers of Bochs and it only (in theory) will work on nix. afaik, it's not implemented specifically; it just might work because Bochs has support for reading from /dev/ in general.
Post Reply