Tips and Tricks

Turbocharge Terminal Services

Here are some tips for keeping disk consuption to a minimum and improving server performance.

If you’re using Windows 2000 Terminal Services to provide users with remote application access, you probably spend more than a little time trying to tweak performance. After all, hearty server hardware is expensive; squeezing just a few more users onto the hardware you have is always a good idea.

Disk space, especially on the system drive, is often one of the biggest performance challenges on a busy terminal server. One problem can result from maintenance: Service packs and hotfixes take up space, and if you didn’t plan for them in the beginning, it’s easy to run out of space. If necessary, buy a product like Partition Magic (www.partitionmagic.com) that’ll let you resize your system disks to accommodate the bloat that comes with regular updates.

Most companies running Terminal Services use roaming profiles, as they’re the only way to ensure a consistent user experience in a terminal server farm. Unfortunately, those profiles mean even more lost disk space, since every profile gets copied into the Documents and Settings folder of every terminal server a user signs on to. Profiles can be pretty large, and aren’t often smaller than 50MB by the time you account for My Documents and other space-hungry folders. Figure 200 users in your organization and that’s 10GB down the drain!

Disk space plays a core and often overlooked role in Terminal Services performance. Sure, processor and memory are important (and when isn’t “add RAM” the right answer?), but Terminal Services can run through disk space a lot faster than you might think, causing basic performance problems that can be hard to pinpoint.

Here are some tips for keeping the disk consumption to a minimum and improving terminal server performance:

 Keep the system drive reserved for the OS, and don’t store Documents and Settings there. Move Documents and Settings to its own partition, so that if it fills up, it won’t take the whole server with it. Microsoft Knowledge Base article 236621, “Cannot Move or Rename the Documents and Settings Folder,” describes in detail how to move the folder.

 Small profiles are a worthy goal anytime you’re using roaming profiles, and especially with Terminal Services. Use Group Policy to redirect My Documents and other profile folders to users’ home directories on a file server. That’ll markedly reduce the size of profiles, ensure that the files are always available to the users, and make logging on and off much quicker.

 Use Group Policy to remove the cached profiles that get created on terminal servers. Cached profiles can be useful on workstations when a domain controller might not be available to process a logon, but on a terminal server cached profiles just waste disk space.

 You may not realize it, but all those user profiles sailing to and from your terminal servers are creating a major disk fragmentation problem. This problem is worse when the profiles are on the system drive, which is their default location; but no matter where you have the profiles stored, you’ll want to schedule a regular defragmentation. Either use Windows’ built-in tool or a more robust third-party tool like Diskeeper (www.executivesoftware. com). I schedule a monthly defrag, and I find it keeps performance nice and smooth.

 Get the page file off of the system drive, if at all possible. Instead, create multiple page files spread across multiple physical disks, if you can, or put the page file onto a RAID-5 array. The more disks that you have to spread the page file across, the happier Terminal Services will be. Removing contention between the page file, user profiles, and the operating system will also improve performance. And while you’re messing with the page file, set its minimum and maximum size to be the same value, typically about 2.5 times the amount of physical RAM in the server. Setting these values to be the same prevents the operating system from spending time resizing the file.

About the Author

With more than fifteen years of IT experience, Don Jones is one of the world’s leading experts on the Microsoft business technology platform. He’s the author of more than 35 books, including Windows PowerShell: TFM, Windows Administrator’s Scripting Toolkit, VBScript WMI and ADSI Unleashed, PHP-Nuke Garage, Special Edition Using Commerce Server 2002, Definitive Guide to SQL Server Performance Optimization, and many more. Don is a top-rated and in-demand speaker and serves on the advisory board for TechMentor. He is an accomplished IT journalist with features and monthly columns in Microsoft TechNet Magazine, Redmond Magazine, and on Web sites such as TechTarget and MCPMag.com. Don is also a multiple-year recipient of Microsoft’s prestigious Most Valuable Professional (MVP) Award, and is the Editor-in-Chief for Realtime Publishers.

comments powered by Disqus

Reader Comments:

Tue, Mar 2, 2004 Brad Gerard Anonymous

Great article - with the exception of putting the swap file on a RAID 5 array.

If you do that, then you will have a ton of overhead as the array (hopefully hardware and not software) will have to deal with the parity information for every read and write access to the swap file. If it is getting hit a lot, this will mean a lot of overhead. (Remember, in a RAID 5 array there are 2 read IOs and 2 write IOs for every write the OS does to the array.)

Using multiple spindles (disks) to stripe the volume is a good idea. I use many small drives instead of a few big ones. Also, I use a RAID 10 (aka 0+1 or 1+0) array. There is 50% overhead due to the mirroring but two things to consider -

a) Drives are cheap

b) With RAID 10, you can loose multiple drives and still be running. As you add more drives to the array you increase the risk of loosing one as well. So the ability to lose more than one is an apealing aspect of RAID 10.

Just my two cents....

Mon, Oct 20, 2003 Anonymous Anonymous

Realy helpfull tips, THAnks

Wed, Sep 17, 2003 Alvin Uruguay

Cool! I've reach this doc trying to find out how to move 'Docs and settings' folder; the method referenced above (all users, system already installed) didn't work at all; if someone knows a good method, please tell me. As for the document... thanks a lot, it worths the time used to read it! Cheers, Alvin.

Sat, Aug 9, 2003 Anonymous Anonymous

important things to keep in mind considering

Sun, Aug 3, 2003 fred Anonymous

important things to keep in mind considering how necessary TS is to an administrator and how easily space disappears.

Fri, Aug 1, 2003 Anonymous Anonymous

To the point.

Tue, Jul 29, 2003 Anonymous Anonymous

A lot of people overlook the value of defraging their TS. It's worth the extra ca$h to maintain performance.

Placing your page file on RAID-5 is a stupid idea. If you engineer your system with enough memory you should only need to move the page file off of the OS drive to increase performance.

Tue, Jul 29, 2003 Anonymous Anonymous

good tips in a concise fashion

Add Your Comment Now:

Your Name:(optional)
Your Email:(optional)
Your Location:(optional)
Comment:
Please type the letters/numbers you see above

Redmond Tech Watch

Sign up for our newsletter.

I agree to this site's Privacy Policy.