I suppose we can start out the new month with a informative post today. At work some friends were setting up some Windows XP machines and wanted to image the disk so that the process for setting up all eight machines went faster. Having no access to disk imaging software at the moment I suggested that they just use `dd` in Linux to do the image. None of them had really heard of this program, so I explained to them how to use it.
A easy way for anyone to do this is to grab a boot-able Linux CD, we used TRK, and grab a external USB hard disk.
Boot from the CD, and choose the first boot option. Mount your USB disk somewhere easily accessible. We did ours as such:
mount /dev/sdb1 /mnt0
then we created an image of the first computer (the one we are currently on, and has Windows XP installed on it already and configured):
dd bs=16384 if=/dev/sda of=/mnt0/image.img
Once the process is complete power off the machine and take the USB hard drive and CD to the next, boot from the CD and mount the hard disk. Issue the command:
dd bs=16384 if=/mnt0/image.img of=/dev/sda
As you can see, `if=` is the Input File for dd, and `of=` is the Output File. `bs=` is the block size to copy between the disks, you can increase this if you wish to see better performance in faster machines.