< Day Day Up > |
No matter which version of Windows you use to get a hard disk ready for use, you have two big decisions to make:
Read on to discover what this means, which versions of Windows support which type, and when to select a particular option. File Systems Used by WindowsWhat exactly is a file system, anyway? A file system describes how data and drives are organized. In Windows, the file system you choose for a hard disk affects the following:
How quickly do you need to decide this? You must choose a file system during disk preparation, although you can sometimes change to a better one later.
What are your options? Windows 9x and Windows Me give you these choices:
Windows NT/2000/XP can create the following file systems on a new drive:
Allocation Units (Clusters) and File SystemsThere are many reasons to choose one file system over another when you prepare a hard disk with Windows, but one of the most important reasons has to do with how Windows creates and keeps track of the files you and Windows make. As you learned in Chapter 14, "Storage," the basic unit of disk management is called the sector. Each and every sector on any hard or floppy disk contains exactly 512 bytes of data if you use standard Windows disk-preparation tools.
Life would be really simple if Windows could use individual sectors when it stores data. Instead, in almost every case, Windows uses various groups of sectors called clusters (by old-timers) or allocation units (a more recent term that sounds bureaucratic but means exactly the same thing) to store data on most types of disk drives. An allocation unit is the smallest amount of disk space an operating system can use to store a file. Even if a file uses less than an allocation unit, the operating system must still allocate the entire allocation unit to that file. Various file systems use varying numbers of allocation units to save a file and, to make matters worse , the allocation unit size varies with the size of the disk.
Why does Windows use allocation units (groups of sectors) instead of individual sectors to store files? Because in most cases the number of sectors is too big for Windows to keep track of on a disk drive. Here are two examples: Example #1 : A 3.5-inch 1.44MB floppy disk has an allocation unit (cluster) size of 512 bytes. In other words, a sector equals an allocation unit. How many allocation units are there on a floppy disk? Let's do the math:
With floppy disks, Windows uses a file system that can keep track of no more than 4,096 (2 12 ) files on a disk. Because 2,847 (the number of sectors) is less than 4,096, it's no problem to use each sector individually for data storage. What happens with a hard disk? The 12-bit (2 12 ) file system that Windows uses for floppy disks isn't large enough to handle a hard disk, even a modestly sized one. Example #2 : One of my computers has an old 1.2GB hard disk, which contains 2,503,872 sectors. At 512 bytes per sector, the drive has a capacity of 1,281,982,464 bytes. This hard disk was introduced when Windows 95 was new. Windows 95 originally used a file system called FAT16, which was designed to handle up to 65,536 (2 16 ) files per drive for hard disks. This number is many times smaller than the number of sectors on the drive. The solution? Divide the sectors into groups called allocation units. The number of allocation units must be at or below the maximum number of files the file system can manage. How many sectors are needed to make an allocation unit with this drive? Let's try some math, and this time let's use a table (see Table 15.1) to set up the calculations. Table 15.1. Calculating a Valid Allocation Unit (Cluster) Size
Here's what's going on in Table 15.1. The allocation unit (cluster) size must result in less than 65,536 files per drive so that Windows 95 can manage the hard disk. To calculate this value, we start by taking the sector size (S) and multiplying it by different values of sectors per cluster (C). This calculation (SxC) creates the value in "Number of Bytes Per Cluster" (B). When B is used to divide the disk capacity (D) to determine the number of files per drive (N), N is compared to 65,536 (the maximum number of files that Windows 95 can manage on the drive). A value for N that is equal to or less than 65,536 can be used as the allocation unit (cluster) size for the drive. As you can see from Table 15.1, this hard disk must use a cluster size of 32,768 (64 sectors) to store a file if the drive is used as a single drive letter. However, smaller hard disk drives using the same FAT16 file system can use smaller cluster sizes. Table 15.2 shows how the cluster sizes vary with hard disk drive sizes. If a large drive is split up into two or more drive letters, the allocation unit size is determined from the size of each drive letter. Table 15.2. FAT16 Drive and Allocation Unit Sizes
What is the practical impact of larger allocation unit sizes as drive size increases ? Because an operating system must use an entire allocation unit to store a file, even if the file is smaller than the allocation unit, larger allocation unit sizes waste disk space. Let's assume that you want to save a file that requires 5,684 bytes of disk space. How many sectors does this file require? 5684/512=7. However, in the real world, when you save a file on a hard disk, you use allocation units, not individual sectors to save a file. Figure 15.1 shows you how much disk space is wasted when you save this file on drives with varying allocation unit sizes. Figure 15.1. As allocation unit (cluster) sizes increase from 2KB (4 sectors) up through 32KB (64 sectors), a file with an actual size of 7 sectors uses less and less of an allocation unit.
As you can see from Figure 15.1, the remainder of the allocation unit cannot be used by another file, and is wasted space.
You might be wondering what has happened to enable Windows to use 40GB, 80GB, 120GB, and even larger drives. More efficient file systems that use fewer sectors per cluster is the answer, and in the following sections you'll learn more about these newer file systems. FAT16FAT16 (also referred to as FAT) is the oldest and simplest file system used by modern versions of Windows, dating back to MS-DOS versions 3.3 and above. Windows 9x's version of FAT16 is similar to that of MS-DOS, but it permits the use of long filenames and enhanced file attributes, storing the date a file was created, last modified, and last viewed . FAT16's highlights include
As you have already learned from Figure 15.1, if you use hard disk drive sizes of 1,024MB or above with the FAT16 file system, the 32KB allocation unit size could cause as much as 30% 40% of your disk to be wasted! So, there are lots of reasons not to use FAT16 anymore:
To overcome these limitations, FAT32 (large disk support) is the default for preparing drives with the Windows 98 and Windows Me Fdisk program, and it's an option with the Windows 95B and Windows 95C Fdisk program. Note that FAT16 is the only file system supported by the original version of Windows 95 and Windows 95a. FAT32FAT32 was introduced with late OEM versions of Windows 95 (Windows 95 OSR 2.0 and above; also referred to as Windows 95B or Windows 95C ). FAT32 is also known as large disk support . FAT32 has the following benefits when compared with FAT16:
Table 15.3. FAT16 and FAT32 Disk Usage Compared
Obviously, FAT32 is a much better choice than FAT16 with any hard disk these days. So, what do you need to prepare a hard disk with a bigger, smarter FAT? You can prepare a drive as a FAT32 drive if the following requirements are met:
Virtually all systems shipped with Windows 98 or Windows Me preinstalled will use FAT32 for their hard drives. (Windows 95B or Windows 95Cbased systems often used FAT16.) But, if you're curious , follow this procedure to determine what file system has been used on a hard drive in a system running Windows:
Unless the system occasionally must be booted with MS-DOS or older versions of Windows, FAT32 is the recommended file system for use with Windows 98 or Me because of its efficient use of disk capacity. If you must boot a Windows 98 or Me system with older versions of Windows, or with MS-DOS, you will need to use the FAT16 file system for any drives you want to access with older versions of Windows or with MS-DOS. However, if a Windows 98 system is accessed over a network, any operating system used on the network can access the files on a FAT32 drive because Windows reads the files before sending them to the other stations on the network. NTFSThe New Technology File System (NTFS) is the native file system of Windows NT and its descendants (Windows 2000 and Windows XP). NTFS has many differences from FAT16 and FAT32, including
NTFS 5.0, the version of NTFS used by Windows 2000 and Windows XP (and by Windows NT 4.0 when Service Pack 4 is installed), supports these additional goodies :
So, what happens when a system running Windows NT 4.0 gets updated to Windows 2000 or Windows XP? When a Windows NT 4.0 system using NTFS 4.0 is upgraded to Windows 2000 or Windows XP, the NTFS 4.0 file system is upgraded to NTFS 5.0.
If you plan to dual-boot Windows NT 4.0 and Windows 2000, you'd better make sure Windows NT 4.0 has been upgraded to Service Pack 4 or above; older versions of Windows NT 4.0 cannot access an NTFS 5.0 partition. Windows 2000 and Windows XP drives can be prepared with FAT16 or FAT32 partitions, but this is recommended only if the drive will be used in a dual-boot configuration with Windows 98 or Windows Me or a similar operating system that does not support NTFS. Follow these steps to determine what file system was used to prepare a Windows NT, 2000, or XP hard drive:
HPFSThe OS/2 High Performance File System (HPFS ) was supported by Windows NT 4.0 but is not supported by Windows 2000 or Windows XP. HPFS partitions should be converted to NTFS with the Convert.exe program before you upgrade a system running HPFS drives to Windows 2000 or Windows XP. Primary and Extended PartitionsThere are two steps involved in preparing a hard disk:
What is a disk partition? A disk partition is a logical structure on a hard disk drive that specifies the following:
Although the name "disk partition" suggests the drive will be divided into logical sections, every ATA/IDE and SCSI hard disk must go through a partitioning process, even if you want to use the entire hard disk as a single drive letter. All versions of Windows support two major types of disk partitions:
Only one extended partition can be stored on each physical drive. If the drive will be used by a single operating system, one of these three ways of partitioning the drive will be used:
You can also leave some unpartitioned space on the hard disk for use later, either for another operating system or another drive letter. Partitioning creates drive letters; formatting creates file systems on the drive letters created during partitioning. Figure 15.4 helps you visualize how these different partitioning schemes can be used on a typical hard disk. Figure 15.4. Typical disk partitioning schemes used for the first hard disk (first four examples) or an additional drive (last two examples).
Drive Letters and Partition Types with Windows 9x/MeIf you're adding an additional hard disk to a system running Windows 9x/Me, it's critical that you partition it with an extended partition. If you prepare it the same way the original drive is prepared (with a primary partition and possibly logical drives) and if the original system has hard disk drive letters C: and D: or C:, D:, and additional drive letters, the new drive will take over drive letters starting with D:. Table 15.4 indicates how Fdisk (the disk partitioning program used by Windows 9x/Me) assigns drive letters; study this for a moment and you'll understand why. Table 15.4. Fdisk Drive Letter Assignments by Priority
What kind of a mess can happen? Assume that you have a single hard drive divided into C: and D: logical drives. C: is the primary partition; D: is a logical drive inside an extended partition. When you add a second hard drive to expand capacity, you want to use the next available drive letters, starting with E:. Figure 15.5 compares the results of placing a primary partition and an extended partition (containing one logical drive) on the second hard disk versus preparing the second hard disk as an extended partition with logical drives with Fdisk (the disk partitioning tool used by Windows 9x/Me). Figure 15.5. Comparing an unpartitioned second hard disk (top) with the same drive partitioned with a primary and extended partition (middle) and as an extended partition (bottom). Note how the drive letters are scrambled when the second drive has a primary partition, but the drive letters are in proper sequence when an extended partition is used.
Note that setting up a primary partition on the second drive creates an almost unmanageable problem, because you will need to copy all the contents of the "old D:" (now E:) drive to the "new D:" drive, and so on. The chances of data loss are fairly high in such a case. And, the primary partition on the second drive is virtually useless because you would need to use advanced BIOS options or a boot manager to use any drive other than C: as a bootable drive. If you are adding a second (or third or fourth) hard drive to a system running Windows 9x/Me and you want its drive letters to follow the existing drive letters, prepare the new drive with an extended partition occupying 100% of the space on the drive. There's no need to use a primary partition for any drive other than the first hard drive in a system unless you are installing an additional operating system. If an additional drive is added as an extended partition, its logical drives will follow the existing drive letters (refer to Figure 15.5). tip
|
< Day Day Up > |