This topic explains how to use the Diskpart tool to align I/O with storage track boundaries.
With a disk that maintains 64 sectors per track, Microsoft Windows always creates the partition starting at the sixty-forth sector, therefore misaligning it with the underlying physical disk. To be certain of disk alignment, use Diskpart.exe, a disk partition tool. Diskpart.exe is a tool provided by Microsoft in the Windows Server 2003 Service Pack 1 support tools that can explicitly set the starting offset in the master boot record (MBR). Setting the starting offset correctly will align I/O with storage track boundaries and improve disk performance. Programs like Microsoft Exchange Server 2007 write data in multiples of 8-kilobyte (KB) I/O operations, and I/O operation to a database can be from 8 KB to 1 megabyte (MB). Therefore, make sure that the starting offset is a multiple of 8 KB. Failure to do so may cause a single I/O operation spanning two tracks, causing performance degradation.
This is exactly the same for Exchange 2003 (4-kilobyte blocks) and SQL server!
Before You Begin
Diskpart is a data-destructive tool. When used against a disk, all data on the disk will be deleted during the storage track boundary alignment process. Therefore, if the disk on which you will run Diskpart contains data, back up the disk before performing the following procedure.
|Diskpart can only be used with basic disks. Diskpart cannot be used with dynamic disks. Diskpart supersedes the functionality previously found in Diskpar.exe. Diskpar and Diskpart should only be used if the drive is translated as 64 sectors per track.|
|Many vendors now have specific tools and guidance for sector aligning their storage platform. You should check with your storage vendor before performing a sector alignment change with Diskpart. If your storage vendor does not have tools for this task or specific guidance for sector aligning their storage platform, we recommend that you use Diskpart to properly align your storage volumes.|
To perform this procedure, the account you use must be delegated membership in the local Administrators group.
To align I/O with storage track boundaries using Diskpart.exe
- If the disk you are aligning is already blank (raw), proceed to Step 3. If the disk contains data, back up the disk before proceeding.
- Delete all partitions on the disk.
- Open a Command Prompt window, and run Diskpart.exe.
- At the Diskpart command prompt, type List Disk and press ENTER. If the disk you want to align does not appear in the list, make sure that it exists and is accessible using the Disk Management snap-in.
- At the Diskpart command prompt, type Select Disk X, where X is the number of the disk as shown in the output of the List Disk command. Diskpart should return a message that indicates that Disk X is the selected disk.
- At the Diskpart command prompt, type Create Partition Primary Align=X, where X is the value recommended by your storage vendor. If your storage vendor does not have any specific recommendations, we recommend that you use 64.
- At the Diskpart command prompt, type Assign Letter=<DriveLetter>.
- After the drive letter is assigned, type exit to exit the Diskpart tool.
- Use the Disk Management snap-in or the Format command to format the partition as an NTFS-formatted partition.
Applies to: Windows 2000 and Windows Server 2003.
Not applicable: Windows Server 2008