Kernel truncates after trying to run it from virtual box

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
User avatar
drunkenfox
Member
Member
Posts: 46
Joined: Tue Mar 13, 2012 10:46 pm

Kernel truncates after trying to run it from virtual box

Post by drunkenfox »

After recently installing linux mint for OS development, I've ran into problems after copying the file to a floppy. First of all, I copy kernel.bin to the root of the floppy and make sure it is its original size. That goes fine. But, when I run off the floppy with virtual box and go into grub and type "kernel /kernel.bin", it gives me the well known error 13. I closed virtualbox and went back to the floppy, to find out that kernel.bin was 0 bytes in size :!:

Any reason why this happens?
;goodbye OS, hello BIOS
mov eax, FFFFFFF0h
jmp eax
User avatar
NickJohnson
Member
Member
Posts: 1249
Joined: Tue Mar 24, 2009 8:11 pm
Location: Sunnyvale, California

Re: Kernel truncates after trying to run it from virtual box

Post by NickJohnson »

I assume you have the floppy loopback-mounted somewhere. Did you unmount it properly before running the VM?
User avatar
bluemoon
Member
Member
Posts: 1761
Joined: Wed Dec 01, 2010 3:41 am
Location: Hong Kong

Re: Kernel truncates after trying to run it from virtual box

Post by bluemoon »

Did you sync?
User avatar
drunkenfox
Member
Member
Posts: 46
Joined: Tue Mar 13, 2012 10:46 pm

Re: Kernel truncates after trying to run it from virtual box

Post by drunkenfox »

Alright, I'll use sync when I get home today. Just read about it and it should solve the problem.
;goodbye OS, hello BIOS
mov eax, FFFFFFF0h
jmp eax
User avatar
drunkenfox
Member
Member
Posts: 46
Joined: Tue Mar 13, 2012 10:46 pm

Re: Kernel truncates after trying to run it from virtual box

Post by drunkenfox »

Thanks bluemoon, it worked =D>
;goodbye OS, hello BIOS
mov eax, FFFFFFF0h
jmp eax
Post Reply