root
Moderator
 Moderator
| Posts: 121 |   | Karma: 1
|
Re: How to Copy my Bootsector to a Floppy with dd command - 2005/03/25 02:30
Hello,
You can stay in the Linux shell and execute:
| Code: |
$ dd if=my-boot-sector of=/dev/fd0 bs=512 count=1
|
Or if you'd like to make a floppy image
| Code: |
$ dd if=/dev/zero of=my-image.bin bs=512 count=2880
$ mkfs.msdos my-image.bin
$ dd if=my-boot-sector of=my-image.bin bs=512 count=1
|
The first line will create a zero filled file with 512 * 2880 bytes, which is exactly the size of a floppy. The 2nd will create FAT12 structures in the image and the last, as above, will copy the bootsector.
The 2nd command might be rewritten on some system, as it first shoud be mounted as a loop device (/dev/lo*), but it should work this way.
Good luck!
|