Disk quotas are set at the volume level only.You cannot create different quotas for individual folders within a volume. If you need to set different quotas for the same users on different folders, you can put those folders on separate volumes or purchase third-party software that allows for more gran- ular setting of quotas. Likewise, you cannot set quotas at the physical disk level. If a disk has three vol- umes on it, each volume is managed separately.You must have administrative rights to assign quotas. Use disk quotas in the following situations: ■ You have limited shared storage available on public servers and need to ensure that the disks don’t become full. ■ You want to keep a log of how much disk space is being consumed by each user. Enabling and Configuring Disk Quotas You can enable disk quotas by accessing the Properties sheet for a volume and using the Quota tab. If you do not see a Quota tab on the Properties sheet, either you do not have administrative rights on the machine or the volume is formatted with FAT or FAT32. Remember that disk quotas can only be configured on NTFS volumes. The Quota tab (Figure 5.76) contains valuable information and you should be familiar with all the options on this tab.The first thing you see on the Quota tab is the “stop light.” It indicates the status of disk quotas on the volume: ■ When the light is red, disk quotas are disabled. ■ When the light is yellow, the system is rebuilding disk quota information. ■ When the light is green, disk quotas are enabled and active. When you select the check box next to Enable quota management, the light goes from red to yellow to green. However, the light may appear to go straight to green.This just means that the quota information was built very quickly and didn’t register on the light. After you enable disk quotas, you must configure how they will be used. By default, users are not denied disk space or warned about the amount of disk space they are using.This is the proper setting if you are only using disk quotas to track how much space each user is using, but if you want to limit the amount of space available to users, you must further configure the quotas feature.This is where the Deny disk space to users exceeding quota limit check box comes into play. When you check this checkbox, Windows will deny additional disk space to anyone who exceeds his or her limit. You can either set limits for users individually by using the Quota Entries button or you can configure a default limit that will apply to everyone.You can also import quota settings from another volume.This is useful if you want to set the quotas identically on a number of different volumes. There are two settings to configure for each user (or for all users as the default): a limit level and a warning level: ■ Next to Limit disk space to, there are two boxes.The first box is a text field into which you can type a number.The second box is a drop-down box that contains a disk measure- ment unit (KB, MB, GB,TB, PB, EB). By entering a number in the first box and choosing 156 Chapter 5 • Managing Physical and Logical Disks 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 156 a measurement from the second box, you can restrict each user to a disk space limit ranging from 1KB to 6 EB.The default limit is 1KB. ■ Directly under the limits boxes are identical Set warning level to boxes. Quota warnings are configured in the same ways as quota limits.You should set the warning level to a smaller number than the disk limit so that users will know they are approaching their limits before reaching them. Table 5.6 explains the different disk measurement options available for setting limits and warnings. Table 5.6 Understanding Disk Measurements Measurement Description KB KB stands for kilobyte. One kilobyte equals one thousand bytes (1,024 bytes in decimal). MB MB stands for megabyte. One megabyte equals one million bytes (1,048,576 bytes in decimal). GB GB stands for gigabit. One gigabit equals o ne billion bytes (1,073,741,824 bytes in decimal ). TB TB stands for terabyte. One terabyte equals one thousand billion bytes (1,099,511,627,776 bytes in decimal —that is a thousand gigabytes). PB PB stands for petabyte. One petabyte equals one thousand terabytes (1,125,899,906,842,624 bytes in decimal ). EB EB stands for exabyte. One exabyte equals one quintillion bytes (a billion gigabytes—1,152,921,504,606,846,976 bytes in decimal ). Finally, you can configure the logging options. Under Select the quota logging options for this volume you have two options: ■ Log event when a user exceeds their quota limit ■ Log event when a user exceeds their warning level Both options are disabled by default and either or both can be enabled by checking the corre- sponding check box(es). Both settings log events to the system log of the event viewer. Logging options are set only on a per-volume basis; there is no setting for logging on an individual user’s Quota Settings page. Enabling disk quotas and setting quota limits 1. In Windows Explorer or My Computer, right-click the volume on which you want to set quotas and select Properties from the context menu. In this example, we enable quotas on the C drive. Note that to manage quotas on a remote computer, you’ll need to first map a network drive for the remote volume on which you want to set or manage quotas. 2. Click the Quota tab, as shown in Figure 5.76. Managing Physical and Logical Disks • Chapter 5 157 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 157 3. Check the check box next to “Enable quota management” to enable disk quotas for the C drive. 4. Check the check box next to “Deny disk space to users exceeding quota limit”to enforce limits. 5. Click the Quota Entries button to open the Quota Entries console, as shown in Figure 5.77. 6. Click the Quota menu bar. 7. Select New Quota Entry from the menu. 158 Chapter 5 • Managing Physical and Logical Disks Figure 5.76 Enabling Disk Quotas Figure 5.77 Viewing Quota Entries 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 158 8. You are prompted to choose the users for which you want to add quotas, as shown in Figure 5.78.Type the user’s name in the box and click Check Name to verify that the user exists in the account database. 9. If the name is verified, click OK to continue.You next have to customize the quota entry for the user, as shown in Figure 5.79. 10. Select “Limit disk space to” and enter the amount of space you wish to allow the user to use on the volume. Select a unit of measurement. 11. Set the warning level for your user in the same way. 12. Click OK to save the settings and add the user to the Quota Entries list. Monitoring Disk Quotas Now that you know how to enable disk quotas, we will discuss how to analyze the quota settings and monitor disk usage. Disk quota settings are accessed and disk usage is monitored via the Quota Entries console, as previously shown in Figure 5.77. The Quota Entries console displays seven items in regard to each user.You can sort by the columns by clicking the corresponding section of the column title bar or by using the View menu (View | Arrange Items | by…). For example, if you want to sort by the amount of disk spaced used, click on the Amount Used bar.This will arrange the user accounts in order of least to greatest space used. Clicking the same column header again will rearrange the accounts in the opposite order (greatest to least). Managing Physical and Logical Disks • Chapter 5 159 Figure 5.78 Choosing Users to Restrict Figure 5.79 Configuring Limits and Warnings 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 159 ■ Status This indicates how well the user is complying with the quota limit.There are three possible settings: OK, Warning, or Above Limit.A status of OK indicates that the user hasn’t reached the warning or limit level yet. Warning indicates that the user has reached the warning level, but not the limit level. Above Limit indicates that the user has passed both the warning and limit levels. Sorting by status makes it easy to find all users that have exceeded their limits. ■ Name This is the user’s full name as it appears in Local Users and Groups or Active Directory Users and Computers. ■ Logon Name This is the user’s account name as it appears in Local Users and Groups or Active Directory Users and Computers. ■ Amount Used This shows the total amount of disk space currently being used by the user. ■ Quota Limit This shows the level at which the user will no longer be allowed to save data to this volume. ■ Warning Level This shows the level at which the user will be warned when saving data to this volume. ■ Percent Used This displays the percentage of allocated space that has been used by the user. Sorting by Percent Used is a good way to discover which users may run out of space soon. Exporting and Importing Quota Settings If you have multiple volumes that contain users’ data then you will probably want to apply the same quota settings to all volumes. Also, if you migrate your users’ data from one volume to another, then you need an easy way to reapply all the disk quotas. 160 Chapter 5 • Managing Physical and Logical Disks Figure 5.80 Resolving SIDs to Logon Names 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 160 There are a few different ways to copy disk quotas from one volume to another. If you open the Quota Entries window (as shown in Figure 5.81) for both volumes, you can drag and drop quota limits between the two windows.You can also export all quota settings to a file and import them to another volume.You can use the following steps to export quota settings and import quota settings. Export quota settings 1. Open My Computer. 2. Right-click the volume you want to manage and choose Properties from the pop-up menu. 3. Click the Quota tab. 4. Click the Quota Entries button.This will give you a window similar to Figure 5.81. 5. Click the Quota menu bar and choose Export from the drop-down list.You will now be asked where to save the quota settings, as shown in Figure 5.82. 6. Type in a name and click the Save button to finish the export. Managing Physical and Logical Disks • Chapter 5 161 Figure 5.81 Choosing to Export Quota Settings Figure 5.82 Exporting Quota Settings 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 161 Import quota settings The steps for importing quota settings are very similar to the steps for exporting quota settings. 1. Open My Computer. 2. Right-click the volume you want to manage and choose Properties from the pop-up menu. 3. Click the Quota tab. 4. Click the Quota Entries button.This will give you a window similar to Figure 5.83. 5. Click the Quota menu bar and choose Import from the drop-down list.You will now be asked which quota settings file to import, as shown in Figure 5.84. 6. Navigate to the quota settings file and click Open to import the settings. 162 Chapter 5 • Managing Physical and Logical Disks Figure 5.83 Choosing to Import Disk Quotas Figure 5.84 Importing Disk Quotas 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 162 Disk Quota Best Practices Disk quotas are a powerful feature that give Windows Server 2003 administrators flexible control over disk usage. However, using them incorrectly can be disastrous. Don’t let this keep you from using disk quotas – just learn to use them intelligently. Here are few guidelines that will ensure that enabling disk quotas makes your job as an administrator easier, not more difficult: ■ Set default limits so that all users are restricted in the amount of space they can use by default. Always make your default settings as restrictive as possible, while still providing users with enough space to do their work. It is easier to give users more space if needed than to take space away. Remember that this is only a default setting. It is not a mandatory setting for all your users; it only applies to those user accounts that do not have specific individual settings configured. ■ Use reasonable quota limits. Don’t just take the amount of space available and divide it equally among your users. Sit down and calculate a fair limit, based on user needs. Not everyone needs the same amount of disk space. Power users may need more than standard users.Those who work with and save large graphic or video files need more space than those who work primarily with plain text files. ■ Be realistic in setting the quotas and stick to them unless/until there is a real need to change them. If you set the default limit at 50MB when you know most users are using 200MB, you are setting yourself up for trouble.Try not to get into the habit of setting quotas excessively low and then increasing them when users complain. It is better to give users the right amount of space up front, and be less flexible about increasing the amount. If users know they can easily get their allocations increased by complaining, they will be less motivated to properly manage their files. ■ Delete quota entries for users who no longer need to store files on the volume. Delete or move their files to another volume, to free space for those who need to store data on the volume. ■ When calculating the amount of disk space available for allocating quotas, remember to take into account NTFS overhead. Files can contain up to 64KB of metadata (information about the file) that is not counted against a user’s quota, but does take up space on the disk. Using Fsutil to Manage Disk Quotas If you prefer using a command-line tool instead of the graphical interface, you can perform many of the tasks involved in managing disk quotas with the command-line utility fsutil.exe. Use the com- mand fsutil quota with one of the following parameters to perform quota-related tasks: ■ Fsutil quota disable <volumepathname> To disable quotas on the volume. ■ Fsutil quota enforce <volumepathname > To enable quota enforcement on the volume. ■ Fsutil quota modify <volumepathname> To create a new quota or change an existing one. Managing Physical and Logical Disks • Chapter 5 163 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 163 ■ Fsutil quota query <volumepathname> To list existing quota entries. ■ Fsutil quota track <volumepathname> To track disk usage on the volume. ■ Fsutil quota violations To display detected quota violations. The fsutil commands can be used in a script to automate quota tasks (for example, to set a specified quota limit each time you add a new user). Implementing RAID Solutions There are several options for setting up a RAID environment.You can use either software-based RAID or hardware-based RAID. Software-based RAID is more cost effective because you don’t have to purchase anything extra, but it works only in certain situations and performance is not as good.You cannot easily change from one RAID type to another. If you want to change you must do the following: 1. Back up your data. 2. Erase your existing RAID configuration. 3. Create a new RAID configuration. 4. Restore your data from backup. This section covers the differences between hardware and software RAID and when it is best to use for a given environment. Understanding Windows Server 2003 RAID Windows Server 2003 RAID is software-based RAID. With software-based RAID, all the physical disks are presented to the operating system as they are and the operating system manages them in a RAID configuration.The benefit is that software-based RAID is built into the operating system. The drawback is that the operating system incurs the entire overhead for maintaining the RAID volume. Additionally, there are limitations that apply to software-based RAID that do not apply to hardware-based RAID.You do not have as many RAID options with software-based RAID. Windows Server 2003 supports only three levels of RAID: RAID 0, RAID 1, and RAID 5. In the next sections, we discuss each in more detail. RAID Level 0 RAID level 0 utilizes disk striping. A RAID level 0 volume in Windows Server 2003 is called a striped volume.This version of RAID does not provide any fault tolerance. Level 0 can be implemented as either a software or hardware solution and is supported by all controllers. Because the operating system must be loaded before the striped volume is initialized and made available, a level 0 array cannot be used for the boot or system partitions. RAID level 0 should be used when you are trying to get max- imum performance from your drives. Level 0 is best for data that is not mission-critical or that is backed up regularly. It is good for audio/video streaming, gaming and other applications where perfor- mance is important. Windows Server 2003’s RAID level 0 works with a minimum of two disks and up to a maximum of 32 disks. 164 Chapter 5 • Managing Physical and Logical Disks 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 164 RAID Level 1 RAID level 1 utilizes disk mirroring. A RAID level 1 volume in Windows Server 2003 is called a mirrored volume, and consists of two identical disks.This version of RAID does provide fault toler- ance and is the only one of Windows Server 2003’s software-based RAID levels that can be used for the boot and system partitions. Level 1 can be implemented as either a software or hardware RAID solution. RAID level 1 should be used when you want to provide fault tolerance for the boot and/or system partitions or if you need fault tolerance and have only two disks available. Level 1 is the most expensive form of Windows Server 2003 RAID because only 50% of the disk space that must be purchased is used for data. RAID Level 5 RAID level 5 utilizes disk striping with parity. A RAID level 5 volume in Windows Server 2003 is called a RAID-5 volume. As with disk striping, a RAID-5 volume cannot be used for the boot or system partition because the operating system must be loaded first to initialize the volume and make it available. RAID-5 volumes require a minimum of three disks and work with up to 32 disks.You should use RAID level 5 when you need fault tolerance with better performance and drive utiliza- tion than RAID level 1 can provide. RAID 5 is one of the most popular RAID implementations. However, software RAID 5 is considerably slower than its hardware counterpart, because of the overhead involved in calculating the parity information. It is better for read-intensive applications as opposed to write-intensive ones. Hardware RAID As the name implies, hardware-based RAID uses special hardware to create RAID volumes. A RAID controller is added to your server.The controller handles the overhead of managing the RAID volumes, and this improves performance by removing the processing burden from the oper- ating system.This also removes many of the restrictions imposed by software-based RAID. Because the RAID controller presents the RAID volume to the OS as one disk, you can use hard- ware-based RAID 0 and RAID 5 volumes for the boot and system partitions. Hardware-based RAID provides you with many more RAID levels to choose from.You should refer to the hardware manufacturer’s specification to determine the type of RAID supported and its compatibility with Windows Server 2003.The only real drawback to hardware-based RAID is the price. Server-grade RAID controllers typically cost $750 and up.This can add up quickly when you have a large number of servers. RAID Best Practices After you have made the decision to use a RAID volume, you need to determine which solution best fits your needs. Will it be hardware RAID or software RAID? Disk striping or disk mirroring? How should you set it up? There are no hard, fast rules, only recommendations, but the following provide some general guidelines to follow when setting up your RAID volumes: Managing Physical and Logical Disks • Chapter 5 165 301_BD_W2k3_05.qxd 5/12/04 12:32 PM Page 165 . backup. This section covers the differences between hardware and software RAID and when it is best to use for a given environment. Understanding Windows Server 2003 RAID Windows Server 2003 RAID is software-based. all the physical disks are presented to the operating system as they are and the operating system manages them in a RAID configuration .The benefit is that software-based RAID is built into the. volume in Windows Server 2003 is called a mirrored volume, and consists of two identical disks.This version of RAID does provide fault toler- ance and is the only one of Windows Server 2003 s software-based