Summary disks and partitions

Partitioning info

When a disk is formatted, sectors are created by the manufacturer. Mostly these sectors are 512 kb each. A group of sectors forms a cluster or allocation unit, the smallest unit that can be managed from the operating system. By changing the cluster size, the amount of disk space can be modified and that chances of defragmentation in- or decrease. (bigger sectors, more defragmentation)

A physical disk or a part of a physical disk can be defined as a partition. Each of these partitions contains a partition boot sector with information about the file system and bootstrap-code. Partitions can de defined as a volume or can be part of a volume. 
The Master Boot Record (MBR) contains the bios bootstrap routine, information that directs the starting pc to the active partition that contains the boot information to load the operating system. The partition table on the disk contains the information about the available partitions.
Each partition can contain one file system. MS Dos, Windows 3.x and Windows 95 use FAT(16), Windows 95b, Windows 98 and Windows 2000 do support FAT32. Both FAT systems use a File Allocation Table in which maps the sectors to file names. NTFS uses a object orientated database called Master File Table (MFT) to store information about the location of files and folders. Both the FAT as the MFT are stored in the first clusters of a partition.

FAT(16) and FAT32 file systems can be converted to NTFS by using the 'convert' tool. NTFS file systems cannot be convert to a FAT(16) or FAT32 system with formatting the partition.

Convert drive /FS:NTFS [/v]

/v offers verbose mode. In this mode more information will be displayed after this conversion. If the drive is in use when executing the convert command, it will offer the schedule the conversion after the next reboot. If you use the recovery console, this console has to be reinstalled after the conversion.

FAT(16), FAT32 AND NTFS

FAT(16) FAT32 NTFS

Support by all (incl. Linux)

Windows 95b, 98, 2000

Files and folder level security

Max. 4 GB partition technical (65524 clusters of 32 KB), max 2 GB to maintain compatibility.

Max 216 files. Max. 512 files per folder. (This can be less when using long file names)

Larger partitions than FAT16. Theoretically up to 2 TB. Windows 2000 can format to 32 GB but read up to 2 TB.
Minimum of 512 MB.

Max 65.534 files per folder. (This can be less when using long file names)

Practical limit 2 TB, theoretical 16 exabytes. (EB)
Minimum of 10 MB.

Max 232  -1 files

No security

Not supported by NT 4.0

Disk quotas, disk compression, file encryption

 

Smaller clusters than FAT, more safeguards and faster.
No security

Misc. NTFS functions like reparse points, change journal. Etc.

FAT stands for File Allocation Table, NTFS for New Technology File System.
Small files are placed nearby the MFT when using NTFS. Files smaller than < 2 kb are placed in MFT. NTFS keeps a log file for all major changes to be able to solve problems. NTFS can store much more attributes than FAT and stores security lists on files and folders. NTFS also supports compression and encryption. 

Microsoft recommends only to use FAT on partitions smaller than 2 GB (overhead of NTFS) and dual boot systems.

Diskmanagement

Disks and partitions are managed from the storage area in the Computer Management snap-in which offers Disk Management, Disk Defragmenter, Logical Drives and Removable Storage. The Logical Disk Manager (LDM) handles the communication with the disk system. You can also start diskmgmt.msc if you only want to manage disks and partitions.

To be able to use a disk in Windows 2000, the following steps should be made :

bulletInitialize the physical disk with a storage type. Each disk can only be one storage type, but both storage types are allowed in one system. There are two types :

                Basic storage

This is the classical way of storage. (Windows NT 4.0, Windows 9x, DOS) Each basic disk is divided into primary and extended partitions with logical drives. Only primary partitions can be used a system partitions.
Default all disks in Windows 2000 are basic disks until converted to dynamic storage via Disk Management.
Basic disks cannot be extended without a reboot.
Areas containing partition information (partition table) or boot information (MBR) are stored in first sectors and are not duplicated.

Primary partitions

A basic disk can contain four primary partitions or three primary partitions and one extended partition. Only a primary partition can be marked active to boot a system. To dual boot with Windows 95, that active partition must be FAT, to dual boot with Windows 95 OSR2 or Windows 98, the active partition must be FAT or FAT32.
Windows 9x and DOS only can read one primary- and one extended partition.

Extended partition

An extended partition is created from free space. Each disk can contain only one extended partition.

Dynamic storage

A basic disk can be converted to a dynamic disk via Disk Management if the sector size is not larger than 512 KB and if more than 1 MB of free disk space if available. (Mirrored system or boot disk cannot be converted) Dynamic disks are only supported by Windows 2000 and support an unlimited number of partitions (volumes). Partitions on dynamic disks are called simple volumes. Other dynamic volumes are :

Extended volume

A single volume that is extended with free disk space on the same physical disk.

Spanned volume

Up to 32 disks of different sizes can be used to store data into a spanned volume. When a disk is full, the next volume will be used to store data. (non fault tolerant). Spanned volumes can be expanded with NTFS-volumes. If one part if the volume is deleted, the entire volume is deleted.
A system- or boot volume cannot be extended.

Mirrored volume (RAID 1)

Two identical copies of a simple volume. Mirrored volumes can contain a boot or system partition but must be on a dynamic disk. If a failure occurs, the data is still available but a changeover happens not automatically. Mirroring offers a read performance improvement as the disk with the head closest to the data is used to read it. It decrease write performance as the controller has to write the data on both disks. The can be solved by disk duplexing in which two controllers are used for two mirrored disks. RAID 1 isfault tolerant but not supported by Windows 2000 professional.

Striped volume (RAID 0)

Data is spread over a maximum of 32 disks to create one volume. (not fault tolerant) It offers the best performance in Windows 2000. Data is written in 64 KB units to the disks. Striped volumes cannot be extended or mirrored and must be contain the same amount of free space.

RAID 5 volume

Data is spread over disks and on each disk a parity stripe is written. Minimal three disks required and the maximum is 32 disks. It cannot contain the boot- or system volume. (fault tolerant, not supported by Windows 2000 professional)

Volumes can be FAT, FAT32 or NTFS formatted. Dynamic disks can be expanded without a reboot but must be NTFS-fomatted. Also keep in mind that a simple volume on a dynamic disk that was converted from a basic disk cannot be expanded to an extended or spanned volume. Only volumes that were created on a dynamic disk can be expanded.
Windows 2000 Professional only supports simple, spanned and striped volumes, it does not support disk fault tolerance. (RAID 1 and 5)

A 1 MB LDM database at the end of each dynamic disk contains all important information (partition table, start- and end sectors) of the dynamic disks in a system. This database is updated automatically and used without user intervention if a disk problems occurs. The dynamic disks are part of a disk group. In Windows 2000 there is only one diskgroup that contains all information off the disks in the system. When using LDM Pro from Veritas multiple disk groups can exist within a system. The default disk group name is computer name plus dg0. The information about the diskgroup is stored in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\dmio\Boot Info\Primary Disk Group. The availability of the disk information on the disks offers the ability to move the disk to another system. (see: http://support.microsoft.com/support/kb/articles/Q222/1/89.ASP) General disk information is stored in HKEY_LOCAL_MACHINE\SYSTEM\DISK\Information.
You can use the dmdiag tool to query information about dynamic disks.
Dynamic disks and volumes are not supported on removable media or laptops.

bulletCreate partitions on a basic disk or volumes on a dynamic disk. (Dynamic disks support an unlimited number of volumes)
bulletFormat the disk with one of the following file systems :

        NTFS

NTFS offers file- and folder security, compression, quota management and encryption. Only Windows NT and Windows 2000 can use NTFS. Always use NTFS if you will promote a member server to a domain controller.

        FAT/FAT32

FAT and FAT32 do not offer much facilities that NTFS does. Microsoft recommends it only to use for dual-boot reason or on small partitions..

Boot- and system partition

A system partition is the active partition that contains the hardware-specific files to load the operating system. The boot partition is a primary partition or logical drive that contains the operating system files. The system partition must be on the active partition, the boot partition can be on another primary or extended partition.

Removable media

Windows 2000 supports the following kind of removable-media :

bulletTape devices. Windows 2000 supports (scsi) tape devices like QIC, DAT, 8mm and DLT.
bulletIEEE 1394. A high speed (100 - 400 Mbps) serial bus that can connect up to 63 devices. Storage devices can be connected on-the-fly by using the Serial Bus Protocol-2 (SBP-2). Supported transfer rates :
S100 98 Mbps
S200 197 Mbps
S400 393 Mbps
bulletFiber channel interface.
bulletUniversal Serial Bus (USB) interface. Up to 127 devices can be plugged on-the-fly.

Disk management console

The disk management console (diskmgmt.msc) shows the partitions or volumes for each disk. (basic or dynamic). You can convert a disk via the console or select various options for the partitions or volumes like :

bulletOpen/explorer partition or volume
bulletChange drive letter or path
bulletFormat
bulletDelete logical drive or volume
bulletProperties
bulletGeneral (size- file system info, set compression, set Indexing service and disk cleanup)
bulletTools (error checking, backup, defragmentation)
bulletHardware (disks, trouble shoot and properties)
bulletSharing (default only system share)
bulletWeb sharing  (by default not activated)
bulletSecurity (only on NTFS, default Everyone full control)
bulletQuota (only on NTFS, default not activated)

By default the following colors are used :

bulletUnallocated space -> Black
bulletPrimary partition -> Dark blue
bulletExtended partition -> Green
bulletLogical drive -> Blue
bulletSimple volume -> Olive
bulletSpanned volume -> Purple
bulletStriped volume -> Cadet blue
bulletMirrored volume -> Brick
bulletRAID 5 volume -> Cyan

You can change the default colors via the Settings button.

Reparse points

When creating a partition in disk administrator, you have an additional option if you are creating a primary partition. The wizard offers to "Mount this volume at an empty folder that supports drive paths." If you select an empty folder on an existing logical disk formatted with NTFS, this partition will appear within the folder instead of being a new logical disk. This technology uses NTFS reparse points.

UDF/CDFS

Windows 2000 supports the Universal Data Format (UDF) to read Digital Versatile Disks (DVD) and Compact Disk File System (CDFS) to read and write CD-ROM's. 
Default Windows 2000 does not support writing DVD's. Windows XP will offer this functionality.

Quotas

Disk quotas can be set on a NTFS volume or partition by administrators but are disabled by default.  Quotas cannot be set for folders. The quota is calculated per user by counting the amount of data in use (uncompressed) by files created by the user. Only users that did not have files on the disk do get a quota. Other quotas need to by set manually. You can set a warning (threshold) and a limit level. If a user exceeds a threshold or limit, he/she is not informed. Only a log in the Event database of the server is made when activated. You can deny access to the disk for the user if the quota is exceeded. In this case the user receive a 'There is not enough free disk' message when exceeding the limit.
For administrators you can only set a warning threshold.

Disk quota's are set via Disk Management, partition/volume, properties, Quota tab. You can set the warning- and limit level and if users should be denied access when exceeding a quota limit. You can also specify event warnings when a warning- or limit level is exceeded. The Quota Entries button can be used to look at the disk space used and to change quotas per user.

You can import and export files that contain quota information. The files are not readable by other applications.

Fragmentation

Internal fragmentation

Fragmentation within files, e.g. databases where part of the data is removed. The data is still in the database but marked for deleted and invisible for the end-user. In some cases that application offers a tool to reorganize the database to clear the internal fragmentation.

External fragmentation

Files that are stored on various non-contiguously sectors on a disk. Windows 2000 offers a defragmentation utility to reduce external fragmentation to increase the disk performance. This tool is based on Diskeeper of Executive's software. It can be stored from the Computer Management Console (compmgmt) or dfrg.msc by an administrator

You can analyze a volume to get volume information (size, cluster size, used space) and information about the fragmentation of the volume (file-, directory-, MFT, pagefile- and free space fragmentation) The analysis also shows the most fragmented files and gives a graphic overview in the Analysis display.

You can also defragment a volume with Disk defragmenter. The tool does not defragment the MFT and the pagefile. To defragment the pagefile remove it temporary to another disk, clear the old page file by setting it to 0 mb and defragment the disk, finally place the pagefile back to the old location. Before defragmentation takes place, first an analysis is made. The defragmentation status is shown in the Defragmentation display. Red shows fragmented files, blue shows contiguous files, green shows system file and free space is white.

You can start the Defragmentation tool if you have administrative privileges via System tools or via the tools-tab after querying the properties of a disk. You cannot connect to a remote computer via the console to defragment a volume.

You can use SysInternal's freeware tool PageDefrag to defrag the paging file and registry hives. Ofcourse other third-party tools also offer this option.

Troubleshooting

The most common disk- and volumes problems are :

bulletBootproblems can occur if the MBR (Master Boot Record) is corrupt or missing. You can use the emergency repair disk to solve this problem. A corrupt MBR can be caused by a virus. The Windows 2000 professional disk does contain a AntiVirus program in the \valueadd\3rdparty\ca-antiv directory. (AVBoot) This software creates a boot disk to scan and clean a system, including a new MBR if required.
Microsoft does not recommend fdisk /MBR to re-create a Master Boot Record
bulletBad cables and connectors.
bulletNTFS permissions on boot/system partition are changed.

Tools

You can use mountvol to mount volumes to NTFS folders. In Windows XP and 2003 server the diskpart utility can be used to manage volumes from a commmand-prompt (incl. scripting) and the do other disk related actions. The XP utility FTOnline can be used to temporary mount volume or stripe sets that where created on pre-Windows XP machines.
The Diskuse resource kit utility shows how much diskspace is used by a user.

CHKNTFS is the program the controls the behavior of the Autochk program that runs at boot-time if Windows had an improper shutdown. As the systems writes are 'dirty bit'  when it still has data to write to write to a volume, the system knows when a check is required.

CHKNTFS has these options:

bullet/C <volume>. Runs CHKDSK at the next reboot on the listed volume, but only if the dirty bit has been set.
bullet/D. Runs CHKDSK on any drives that have the 'dirty' bit set at the next reboot. This basically resets CHKDSK to its default behavior.
bullet/X <volume>. Excludes a specified drive from boot-time checking, but only for the next reboot.

FSUtil is a command-line utility to retrieve all kind of disk information from the system.

More information

Related white papers

bulletFile- and print services technical overview
bulletEnterprise class storage
bulletManaging Windows 2000 disks and backup and restore
bulletDisk defragmenter in Windows 2000: Maintaining peak performance through defragmentation

Technet articles on how to increase disk performance

bullet Moving the Windows Default Paging and Spool File (Q123747)
bullet NTFS Performance with Numerous Long Filenames (Q130694)
bullet Windows NT Nonresponsive during NTFS Directory Traversal (Q150355)

Links :

bullet Technical overview of Windows Server 2003 file services
bulletWindows 2000 disk management (Windows 2000 magazine feb 2000)
bulletInside storage management, part 2 (Windows 2000 magazine apr 2000)
bulletInside storage management, part 1 (Windows 2000 magazine mar 2000)
bulletDynamic disks (Swynk)
bullet Dynamic vs. basic storage in Windows 2000 and Windows XP (Q175761)
bulletWindows 2000 clusters and disk configuration (Swynk)
bullet Maximizing ATA disk performance, part 2 (Windows .net magazine mar 2002)
bullet Maximizing ATA disk performance, part 1 (Windows .net magazine, jan 2002)
bulletNTFS alternate data streams (Windows 2000 magazine mar 2001)
bulletInside NTFS part 1 (Windows 2000 magazine nov 2000)
bulletInside NTFS part 2 (Windows 2000 magazine winter 2000)
bulletRethinking NTFS (Windows 2000 magazine aug 2000)
bulletNTFS5 vs FAT32 (Windows 2000 magazine apr 2000)
bulletNTFS information (Windows 2000 mag.)
bullet Description of the FAT32 file system in Windows XP (Q310525)
bulletWindows 2000 disk quota limitations 
bullet Upgrading a RAID 1 configuration (Windows 2000 magazine)
bulletAll about IDE (TechRepublic)
bullet RAID configurations (TechRepublic)
bullet Learn the different RAID levels (TechRepublic)
bulletRAID brings reliability to mass storage (TechRepublic)
bullet Maximize uptime with hot-swap raid (TechRepublic)
bulletUnderstanding RAID from the ground up (TechRepublic)
bullet Consider security before returning a failed hard drive (TechRepublic)
bullet Maximize uptime with hot-swap RAID (TechRepublic)
bulletHarddisk information (Storage guide)
bullet Server defragmentation utilities (Windows & .NET magazine)
bullet Keep your win2k disks maximized with Autodefrag (TechRepublic)
bulletDefragmentation whitepaper (Diskkeeper)
bulletDefragmentation in Windows 2000 (PlanetIT)
bulletThe defragmentation question (PlanetIT)
bulletWinternal's enterprise defragmenters for Windows NT/2000
bulletEnterprise defragmenters for Windows NT/2000: Cost and benefits (Winternals)
bullet Disk defragmenter (Windows 2000 magazine Oct 2001)
bulletScheduling disk defragmenter (Windows 2000 mag.)
bullet Fragmentation in W2K (Windows 2000 magazine Nov 2001)
bullet Nonadministrative Win2K defragmentation (Windows 2000 magazine Nov 2001)
bulletDiskkeeper in Germany
bulletRaxco's on-line fileaccesstimer
bulletReparse points (Microsoft)
bullet Apply disk quotas to groups (Windows 2000 magazine June 2001)
bulletWindows 2000 Disk quota limitiations (Swynk)
bulletChkdsk update (Windows 2000 magazine jul 2001)
bulletHow to enable disk write cache (Windows 2000 magazine)
bullet Seamless storage with RSS (Windows 2000 magazine Dec 2001)
bulletNTFS partition-deletion problems (Windows 2000 magazine)
bullet Best swap file locations (SearchWindows2000)
 
bulletNTFS preinstallation and Windows XP (Microsoft)

Third-party tools

bulletQuota management tools (Windows 2000 magazine jan 2001)
bulletEnterprise defragmentation utilities (Windows 2000 magazine feb 2001)
bulletDiskKeeper defragmentation software
bulletPerfectDisk 2000 (Windows 2000 magazine jul 2000)
bulletStorageCeNTral
bulletWinternals Defrag commander NE
bulletRaxco's PerfectDisk 2000

Last update : 8 March 2003