PFSense - Physdiskwrite - Manuel Kasper

Friday, 13 May 2011 17:47 Manual Kasper


This is a small Windows NT/2000/XP command line tool that makes it possible to write disk images onto raw disks, like CF cards. It currently has a few rough edges, most notably in the selection of the device to be written – you have to decide which device is the right one by looking at the C/H/S values (though if the CF card was the last device to be connected to the system, it usually shows up as the last one in the list).

Note that the C/H/S values may be incorrect for CF cards – looks like this is a bug in Windows. There is some protection against accidentally overwriting your hard disk, but then again, I CAN'T TAKE ANY RESPONSIBILITY FOR LOST DATA – YOU USE THIS PROGRAM ON YOUR OWN RISK.

If you prefer GUIs over command line applications, PhysGUI (written by Urs Zweifel) makes choosing the correct disk to write to easier (it can also identify disks more reliably than physdiskwrite).

Special considerations for Windows Vista/7

physdiskwrite works with Vista, but you must make sure to run it as administrator (simply having admin rights isn't enough), or it won't find any disks. One way to do this is to create a shortcut to cmd.exe, then right-click it and select "run as administrator". Then you can launch physdiskwrite from the command prompt window that appears, and it should work fine.

If you get write errors shortly after physdiskwrite has begun writing to the target disk (usually after 65536 bytes), this may be caused by existing partitions on the disk. Use the Disk Management utility (right-click on the "Computer" icon on the desktop and select Manage, then navigate to Computer Management (Local)/Storage) to delete all partitions on the target disk before starting physdiskwrite.

If you are unable to delete all the partitions with the Disk Management utility, try the following procedure:

  1. Open a command window as admin ("cmd")
  2. Type "diskpart" and hit enter.
  3. Type "list disk" and hit enter to find out the number of your drive.
  4. Type "select disk X" (where you replace X with the number of your drive) and hit enter.
  5. Type "clean" and hit enter.


physdiskwrite 0.5.2 (38 KB)



physdiskwrite [-u] [-d driveno] <image-file>

...or just simply drag-and-drop the image file onto the physdiskwrite.exe icon.

© 2003-2011 by Manuel Kasper < This e-mail address is being protected from spambots. You need JavaScript enabled to view it >. All rights reserved. m0n0wall - physdiskwrite
Last Updated on Friday, 13 May 2011 22:41