Imaging Arcade (or other) Hard Drives using MAME's CHDMAN Utility


What You Will Need:

NOTE: I renamed these to "32" and "64" intentionally for those who want a specific edition.
If you do not know if you are running a 32-bit or 64-bit Windows OS, use the 32-bit edition as it works on 64-bit systems as well.
These CHDMAN files are from the latest stable .130 MAME release.

Image files made using CHDMAN will vary in size and checksum data (based on data from the drive and version of CHDMAN used).
The CHD information for KI and KI2 (presented above) was taken from the 'official' CHD image files (pass CLRMAMEPro audits 100%).



Why Would I Need to Do This?


WARNINGS & DISCLAIMERS

Is it possible to overwrite the wrong drive with this method? YES. If that drive happens to be the one your Windows operating system
is installed on, then you will lose the ability to boot to Windows, and will be searching the Internet for disk recovery software
to recover your data. If you are not comfortable with this fact, then please just buy a KI kit or have someone perform this for you.

DO NOT *EVER* ALLOW WINDOWS TO FORMAT OR PARTITION/MODIFY YOUR
ORIGINAL/SOURCE HARD DRIVE DURING THIS PROCESS (YES, IT WILL BE RUINED).





Before You Begin: Get Organized!


Using CHDMAN to Create A Hard Drive Image (Physical Disk to a File)

  1. Connect the hard drive your would like to image to your PC. The simplest manner is via a USB to IDE (or SATA) adapter.
  2. Click "Start" > Run, and enter diskmgmt.msc. This opens the Windows Disk Management window.
  3. Compare the size of your source hard drive to the sizes of the drives shown in Windows Disk Management. Do you see your drive?
  4. Record the Disk Number that Windows has assigned the drive.


    Your "C" drive will usually be Disk 0, and in this example my KI 2 drive was assigned Disk 1.

    If Killer Instinct 2 is a 420.8MB drive - why does Windows show it as a 400MB drive?
    Either ignore it, or learn all about it - Forever yours, Microsoft.




Killer Instinct (and many other) hard drives will not be assigned a drive letter.
They will be shown as unknown, unallocated, not initialized, or RAW. This is NORMAL.

  1. Once you have noted the Disk Number assigned to your drive, you can close this window.
  2. Open a DOS command window: Click "Start" > Run, and enter cmd
    NOTE: In Vista/Windows 7, use "Start" > "All Programs" > "Accessories" > Right-Click "Command Prompt" and select 'Run as Administrator'
  3. Change to the directory with your CHDMAN file(s). This tutorial will use C:\KI.



This image shows our "KI" directory listing with the CHDMAN executables present.


Type the name of the executable (with no switches) to see all of the commands CHDMAN is capable of.
  1. To create the KI2 hard drive image, type: chdman32 -createhd \\.\PHYSICALDRIVE1 kinst2hd.chd

This process took the contents of "PHYSICALDRIVE1" and wrote them to a file named kinst2hd.chd.

The PHYSICALDRIVE attribute requires the correct disk number you recorded earlier from Windows Disk Management.
If your source disk number was 3, you would have substituted "\\.\PHYSICALDRIVE3" in the example above.

Congratulations - You have now successfully backed up a physical hard drive to a single image file.
It would be a good idea to burn this file to a CD or DVD so you always have a backup copy available.


Using CHDMAN to Write a Drive Image to a Physical Hard Drive (File to a Physical Disk)

Imaging from an image file (*.CHD) to a physical drive is essentially the opposite of what was covered above.

Notes:

Let's Begin! This example uses a CompactFlash memory card as the destination media:

  1. Connect the hard drive (or alternate media) your would like to image to your PC. The simplest manner is via a USB to IDE/SATA/CompactFlash adapter.
  2. Click "Start" > Run, and enter diskmgmt.msc. This opens the Windows Disk Management window.
  3. Compare the size of your destination drive to the sizes of the drives shown in Windows Disk Management. Do you see your drive?
  4. Record the Disk Number that Windows has assigned the drive.

Your "C" drive will usually be Disk 0, and in this example my 512MB CompactFlash card was assigned Disk 2.

If the CompactFlash card is 512MB, why does Windows show it as a 499MB drive?
Either ignore it, or learn all about it.




  1. Once you have noted the Disk Number assigned to your drive, you can close this window.
  2. Open a DOS command window: Click "Start" > Run, and enter cmd
    NOTE: In Vista/Windows 7, use "Start" > "All Programs" > "Accessories" > Right-Click "Command Prompt" and select 'Run as Administrator'
  3. Change to the directory with your hard drive image and CHDMAN file(s). This tutorial will use C:\KI.


Here we have a directory listing of our folder with kinst2.chd image file and the CHDMAN executables.


The "-info" switch will show the specifications of any hard drive image file.
  1. To transfer the KI2 hard drive image to your physical disk, type: chdman32 -extract kinst2.chd \\.\PHYSICALDRIVE2

This process took the contents of kinst2.chd and wrote them to the physical device "PHYSICALDRIVE2".

The PHYSICALDRIVE attribute requires the correct disk number you recorded earlier from Windows Disk Management.
If your destination disk number was 1, you would have substituted "\\.\PHYSICALDRIVE1" in the example above.



Always "Safely Remove" your USB device from Windows!
(Right Click the USB icon in your taskbar, select 'Safely Remove Hardware')



If you receive a "error writing hunk" message, disconnect and re-connect your destination drive or CF adapter.


IF PROMPTED, DO NOT ALLOW WINDOWS TO FORMAT/PARTITION/MODIFY YOUR NEWLY IMAGED HARD DRIVE!

Congratulations - You have now successfully imaged a CHD image file to a physical hard drive.

Happy Gaming!


Questions about anything on this site? E-mail me: Admin