Page 1 of 1

Create a normal floppy with dd?

Posted: Tue Nov 11, 2014 4:49 pm
by ThisMayWork
I am trying to create a normal in size floppy disk with dd using the following

Code: Select all

dd if=/dev/zero of=os.img count=1440 bs=512
	dd if=boot.bin of=os.img bs=512 count=1
	dd if=kernel.bin of=os.img bs=512 seek=1
However, the resulting floppy is only 6Kb in size, which Virtual Box won't accept. Any ideas?
Thanks in advance!

Re: Create a normal floppy with dd?

Posted: Tue Nov 11, 2014 6:47 pm
by Nable
Oh...
man dd wrote:

Code: Select all

       conv=CONVS
              convert the file as per the comma separated symbol list
[...]

       Each CONV symbol may be:
[...]
       notrunc
              do not truncate the output file
tl;dr: by default dd truncates output file, so you should specify conv=notrunc option.

Re: Create a normal floppy with dd?

Posted: Wed Nov 12, 2014 9:06 am
by ThisMayWork
Thank you, worked like a charm! :)