-2

I am using dd In a windows environment. I know to write a file to the 1st sector of a disk using the command,

dd if=c:\... of=c:\... bs=512 count=1

How to write a file or data to the second sector of a disk using dd?

Undo
  • 25,519
  • 37
  • 106
  • 129
  • Presumably this is about how to test your code you have written. Generic system administration questions otherwise belong on http://superuser.com – Anders Dec 23 '15 at 03:41

1 Answers1

0

To write to the second sector, use these two options seek=1 count=1

Also, note that in your example the if and of parameters are probably wrong. If you are trying to read and write DISKS, ifandofvalues would probably start with/dev/` (depending on what OS you are). Your c:... looks like a beginning of a Windows file name. This may fine, if you are using a Windows port of dd and it accepts file names in this format, but even in this case, they are not DISK names, they are FILE names.

rsteward
  • 1,146
  • 2
  • 8
  • 9