Sunday, December 6, 2009

Windows 7 on SSD - how to create an aligned partition for best performance

and

  How to restore an image with Acronis True Image and keep the partition alignment


Several benchmarks have shown that having an aligned partition on a SSD hard drive will result in better performance (20-50%).
But if you are using Acronis True Image and want to restore an image for some reason, you could loose this precious alignment since True Image could delete the partition first and recreate it unaligned before restoring the data.
I will describe the steps to prevent this.

First I will show the steps for creating an aligned partition before installing Windows 7.
  • boot Windows 7 from the install DVD or a USB pen drive (How to prepare a USB pen drive for installing Windows 7)
  • select language, then "Next"
  • select "Repair your computer"
  • check "Use recovery tools that..", then "Next"
  • select "Command Prompt"
  • diskpart
  • list disk
  • select disk 0
  • clean
  • create partition primary size=32768 align=1024 (size is just an example, this will create a 32 GB partition for C: to install Windows 7 on)
  • create partition primary align=1024 (second partition D:, it will take the rest of the space of hard disk 1)
  • select partition 1
  • active
  • list partition
  • exit
  • close command prompt window
  • continue to install Windows 7 on the newly createted partition (C:)
Important thing here is the parameter align=.., I would recommend the number 1024 to have this partition aligned on a 1024 KByte border (2048 sectors), this should be good choice for any SSD currently available.
(There are SSDs which need at least a 128 KByte alignment, others will need a 512 KByte alignment for best performance. So with a 1024 KByte alignment you will be on the safe side.)






Now if you want to restore the Windows 7 system partition C: from an Acronis image, follow these steps:

  • boot Acronis True Image from a Rescue CD or a USB pen drive
  • select Restore
  • select the source image (C:) you created earlier and want to restore, either from partition D: etc. or an external USB hard disk (must be present when you boot the Acronis rescue media)
  • select the destination: partition 1 / 32 GB (this is our aligned partition)
  • select only NTFS/Volume C:, not MBR/Track0
  • verify the Acronis options: new location(C:), primary, mark as active
  • restore it
This will keep the alignment of the restored partition, it was tested with Arconis True Image Home 2010, Build 6053.


How to verify if the partition is still aligned after Acronis True Image did the restore:

You can do the verification either with Microsoft's command line tool diskpar, this will require some math to calculate the alignment.

Or get a copy of Argus Monitor (the trial version will do), go to the SMART section and select the hard drive you want to check.
Next open the drive information window, scroll to the bottom of that window and you will see the partitions for that drive as well as the alignment of each partition.


Saturday, December 5, 2009

How to prepare a USB pen drive for installing Windows 7

Installing Windows 7 from a USB pen drive can take considerable less time than installing it from a DVD drive. Here are the steps to prepare the USB pen drive.


You will need the Windows command line tool diskpart for this, either the Vista or Windows 7 version. The XP version will not work.

The easiest way is a running Vista / Windows 7 on some other computer. Open a command prompt as administrator and type "diskpart".

If you don't have access to a running Vista / Windows 7, boot a Vista or Windows 7 install DVD, choose "Repair your computer", then "Use recovery tools that.." and finally select "Command Prompt". Type "diskpart".

Either way, once you have diskpart running, these are the next steps:

  • list disk
  • select disk X (X is the number of your USB pen drive you want to prepare for the Windows 7 install files - make sure there is no data on it you still need and make sure you select the right disk - size is a good indicator)
  • clean (double check you have selected the right disk!)
  • create partition primary
  • active
  • format fs=fat32 quick
 



Copy all files from the Windows 7 install DVD or from the .iso image to this prepared USB pen drive.
Make sure your computer will boot from this drive (check BIOS startup settings).

You can now install Windows 7 from this USB pen drive much faster than from the DVD.