Managing File Systems and Drives in Windows Server 2008
- 12/28/2009
- Managing the File Services Role
- Adding Hard Disk Drives
- Working with Basic, Dynamic, and Virtual Disks
- Using Basic Disks and Partitions
- Managing Existing Partitions and Drives
Working with Basic, Dynamic, and Virtual Disks
Windows Server 2008 R2 supports basic, dynamic, and virtual disk configurations. This section discusses techniques for working with each disk configuration type.
Using Basic and Dynamic Disks
Normally, Windows Server 2008 R2 disk partitions are initialized as basic disks. You can’t create new fault-tolerant drive sets using the basic disk type. You need to convert to dynamic disks and then create volumes that use striping, mirroring, or striping with parity (referred to as RAID 0, 1, and 5 respectively). The fault-tolerant features and the ability to modify disks without having to restart the computer are the key capabilities that distinguish dynamic disks from basic disks. Other features available on a disk depend on the disk formatting.
You can use both basic and dynamic disks on the same computer. However, volume sets must use the same disk type and partitioning style. For example, if you want to mirror drives C and D, both drives must have the dynamic disk type and use the same partitioning style, which can be either MBR or GPT. Note that Disk Management allows you to start many disk configuration tasks regardless of whether the disks you are working with use the dynamic disk type. The catch is that during the configuration process Disk Management will convert the disks to the dynamic disk type. To learn how to convert a disk from basic to dynamic, see "Changing Drive Types" on the next page.
You can perform different disk configuration tasks with basic and dynamic disks.
With basic disks, you can do the following:
Format partitions and mark them as active
Create and delete primary and extended partitions
Create and delete logical drives within extended partitions
Convert from a basic disk to a dynamic disk
With dynamic disks, you can do the following:
Create and delete simple, striped, spanned, mirrored, and RAID-5 volumes
Remove a mirror from a mirrored volume
Extend simple or spanned volumes
Split a volume into two volumes
Repair mirrored or RAID-5 volumes
Reactivate a missing or offline disk
Revert to a basic disk from a dynamic disk (requires deleting volumes and restoring from backup)
With either disk type, you can do the following:
View properties of disks, partitions, and volumes
Make drive letter assignments
Configure security and drive sharing
Special Considerations for Basic and Dynamic Disks
Whether you’re working with basic or dynamic disks, you need to keep in mind five special types of drive sections:
Active The active partition or volume is the drive section for system caching and startup. Some devices with removable storage may be listed as having an active partition.
Boot The boot partition or volume contains the operating system and its support files. The system and boot partition or volume can be the same.
Crash dump The partition to which the computer attempts to write dump files in the event of a system crash. By default, dump files are written to the %SystemRoot% folder, but they can be located on any partition or volume.
Page file A partition containing a paging file used by the operating system. Because a computer can page memory to multiple disks, according to the way virtual memory is configured, a computer can have multiple page file partitions or volumes.
System The system partition or volume contains the hardware-specific files needed to load the operating system. The system partition or volume can’t be part of a striped or spanned volume.
Changing Drive Types
Basic disks are designed to be used with previous versions of Windows. Dynamic disks are designed to let you take advantage of the latest Windows features. Only computers running Windows 2000 or later releases of Windows can use dynamic disks. However, you can use dynamic disks with other operating systems, such as UNIX. To do this, you need to create a separate volume for the non-Windows operating system. You can’t use dynamic disks on portable computers.
Windows Server 2008 R2 provides the tools you need to convert a basic disk to a dynamic disk and to change a dynamic disk back to a basic disk. When you convert to a dynamic disk, partitions are changed to volumes of the appropriate type automatically. You can’t change these volumes back to partitions. Instead, you must delete the volumes on the dynamic disk and then change the disk back to a basic disk. Deleting the volumes destroys all the information on the disk.
Converting a Basic Disk to a Dynamic Disk
Before you convert a basic disk to a dynamic disk, you should make sure that you don’t need to boot the computer to other versions of Windows. Only computers running Windows 2000 and later releases of Windows can use dynamic disks.
With MBR disks, you should also make sure that the disk has 1 MB of free space at the end of the disk. Although Disk Management reserves this free space when creating partitions and volumes, disk management tools on other operating systems might not. Without the free space at the end of the disk, the conversion will fail.
With GPT disks, you must have contiguous, recognized data partitions. If the GPT disk contains partitions that Windows doesn’t recognize, such as those created by another operating system, you can’t convert to a dynamic disk.
With either type of disk, the following holds true:
There must be at least 1 MB of free space at the end of the disk. Disk Management reserves this free space automatically, but other disk management tools might not.
You can’t use dynamic disks on portable computers or with removable media. You can configure these drives only as basic drives with primary partitions.
You shouldn’t convert a disk if it contains multiple installations of the Windows operating system. If you do, you might be able to start the computer only using Windows Server 2008 R2.
To convert a basic disk to a dynamic disk, follow these steps:
In Disk Management, right-click a basic disk that you want to convert, either in the Disk List view or in the left pane of the Graphical View. Then click Convert To Dynamic Disk.
In the Convert To Dynamic Disk dialog box, select the check boxes for the disks you want to convert. If you’re converting a spanned, striped, mirrored, or RAID-5 volume, be sure to select all the basic disks in this set. You must convert the set together. Click OK to continue.
The Disks To Convert dialog box shows the disks you’re converting. The buttons and columns in this dialog box contain the following information:
Name Shows the disk number.
Disk Contents Shows the type and status of partitions, such as boot, active, or in use.
Will Convert Specifies whether the drive will be converted. If the drive doesn’t meet the criteria, it won’t be converted, and you might need to take corrective action, as described previously.
Details Shows the volumes on the selected drive.
Convert Starts the conversion.
To begin the conversion, click Convert. Disk Management warns you that after the conversion is complete, you won’t be able to boot previous versions of Windows from volumes on the selected disks. Click Yes to continue.
Disk Management restarts the computer if a selected drive contains the boot partition, system partition, or a partition in use.
Changing a Dynamic Disk Back to a Basic Disk
Before you can change a dynamic disk back to a basic disk, you must delete all dynamic volumes on the disk. After you do this, right-click the disk and select Convert To Basic Disk. This changes the dynamic disk to a basic disk. You can then create new partitions and logical drives on the disk.
Reactivating Dynamic Disks
If the status of a dynamic disk is Online (Errors) or Offline, you can often reactivate the disk to correct the problem. You reactivate a disk by following these steps:
In Disk Management, right-click the dynamic disk you want to reactivate, and then click Reactivate Disk. Confirm the action when prompted.
If the drive status doesn’t change, you might need to reboot the computer. If this still doesn’t resolve the problem, check for problems with the drive, its controller, and the cables. Also make sure that the drive has power and is connected properly.
Rescanning Disks
Rescanning all drives on a system updates the drive configuration information on the computer. Rescanning can sometimes resolve a problem with drives that show a status of Unreadable. You rescan disks on a computer by choosing Rescan Disks from the Action menu in Disk Management.
Moving a Dynamic Disk to a New System
An important advantage of dynamic disks over basic disks is that you can easily move them from one computer to another. For example, if after setting up a computer you decide that you don’t really need an additional hard disk, you can move it to another computer where it can be better used.
Windows Server 2008 R2 greatly simplifies the task of moving drives to a new system. Before moving disks, you should follow these steps:
Open Disk Management on the system where the dynamic drives are currently installed. Check the status of the drives and ensure that they’re marked as Healthy. If the status isn’t Healthy, you should repair partitions and volumes before you move the disk drives.
Check the hard disk subsystems on the original computer and the computer to which you want to transfer the disk. Both computers should have identical hard disk subsystems. If they don’t, the Plug and Play ID on the system disk from the original computer won’t match what the destination computer is expecting. As a result, the destination computer won’t be able to load the right drivers, and boot might fail.
Check whether any dynamic disks that you want to move are part of a spanned, extended, or striped set. If they are, you should make a note of which disks are part of which set and plan on moving all disks in a set together. If you are moving only part of a disk set, you should be aware of the consequences. For spanned, extended, or striped volumes, moving only part of the set will make the related volumes unusable on the current computer and on the computer to which you are planning to move the disks.
When you are ready to move the disks, follow these steps:
On the original computer, start Computer Management. Then, in the left pane, select Device Manager. In the Device list, expand Disk Drives. This shows a list of the physical disk drives on the computer. Right-click each disk that you want to move, and then click Uninstall. If you are unsure which disks to uninstall, right-click each disk and click Properties. In the Properties dialog box, click the Volumes tab, and then select Populate. This shows you the volumes on the selected disk.
Next, on the original computer, select the Disk Management node in Computer Management. If the disk or disks that you want to move are still listed, right-click each disk, and then click Remove Disk.
After you perform these procedures, you can move the dynamic disks. If the disks are hot-swappable disks and this feature is supported on both computers, remove the disks from the original computer and then install them on the destination computer. Otherwise, turn off both computers, remove the drives from the original computer, and then install them on the destination computer. When you have finished, restart the computers.
On the destination computer, access Disk Management, and then choose Rescan Disks from the Action menu. When Disk Management finishes scanning the disks, right-click any disk marked Foreign, and then click Import. You should now be able to access the disks and their volumes on the destination computer.
Managing Virtual Hard Disks
Using Disk Management, you can create, attach, and detach virtual hard disks. You can create a virtual hard disk by choosing Create VHD from the Action menu. In the Create And Attach Virtual Hard Disk dialog box, click Browse. Use the Browse Virtual Disk Files dialog box to select the location where you want to create the .vhd file for the virtual hard disk, and then click Save.
In the Virtual Hard Disk Size list, enter the size of the disk in MB, GB, or TB. Specify whether the size of the VHD dynamically expands to its fixed maximum size as data is saved to it or uses a fixed amount of space regardless of the amount of data stored on it. When you click OK, Disk Management creates the virtual hard disk.
The VHD is attached automatically and added as a new disk. To initialize the disk for use, right-click the disk entry in Graphical View, and then click Initialize Disk. In the Initialize Disk dialog box, the disk is selected for initialization. Specify the disk type as MBR or GPT, and then click OK.
After initializing the disk, right-click the unpartitioned space on the disk and create a volume of the appropriate type. After you create the volume, the VHD is available for use.
Once you’ve created, attached, initialized, and formatted a VHD, you can work with a virtual disk in much the same way as you work with other disks. You can write data to and read data from a VHD. You can boot the computer from a VHD. You are able to take a VHD offline or put a VHD online by right-clicking the disk entry in Graphical View and selecting Offline or Online, respectively. If you no longer want to use a VHD, you can detach it by right-clicking the disk entry in Graphical View, selecting Detach VHD, and then clicking OK in the Detach Virtual Hard Disk dialog box.
You can use VHDs created with other programs as well. If you created a VHD using another program or have a detached VHD that you want to attach, you can work with the VHD by completing the following steps:
In Disk Management, click the Attach VHD option on the Action menu.
In the Attach Virtual Hard Disk dialog box, click Browse. Use the Browse Virtual Disk Files dialog box to select the .vhd file for the virtual hard disk, and then click Open.
If you want to attach the VHD in read-only mode, select Read-Only. Click OK to attach the VHD.