Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

How to: Change Cache Settings for Team Foundation Server Proxy

As a Team Foundation Server administrator, you can change the settings for the version control file cache when you configure Team Foundation Server Proxy after installation or at any other time.

NoteNote:

After installing Team Foundation Server Proxy, you must configure Team Foundation Server Proxy in order to enable and manage the cache. For more information, see How to: Enable Version Control Caching for Team Foundation Server Proxy.

You can change cache settings in the following ways:

  • Specify a different cache root folder.

  • Change the cache limit at which old files are removed from the cache.

  • Change the amount of space to free when old files are removed.

  • Change the interval for saving cache performance information to a file.

You can follow these steps by editing the Proxy.config file on the proxy computer. The Proxy.config file is located in the proxy installation directory. For more information, see The Team Foundation Server Proxy Config File.

NoteNote:

The default proxy installation directory is Drive:\Program Files\Microsoft Visual Studio 2008 Team Foundation Server\Web Services\VersionControlProxy.

After performing one or more of these tasks, you must recycle the application pool by using the IISRESET command to retrieve the latest version of the Proxy.config file.

Required Permissions

To perform this procedure, you must be a member of the Administrators security group on the Team Foundation Server Proxy computer.

In addition to these permissions, on computers that run Windows Server 2008 or Windows Vista:

  • To follow a command-line procedure, you might have to open an elevated Command Prompt. Click Start, right-click Command Prompt, and then click Run as Administrator.

  • To modify web.config files, you might have to open a text editor as an administrator. Click Start, click All Programs, right-click the editor, and then click Run as administrator.

For more information, see the Microsoft Web site.

To specify a different cache root folder

  1. On the Team Foundation Server Proxy computer, create a new cache folder.

    You can create the new cache folder in the following locations: on a local disk, in the UNC path, or on a mounted drive. Make sure that this folder has sufficient space because it can contain files from all Team Foundation servers that the proxy represents.

    Security noteSecurity Note:

    The cache folder stores sensitive information that is not encrypted. Therefore, make sure that only the Team Foundation Server Proxy service account has Read and Write permissions to the cache folder. For more information, see How to: Configure Cache Security for Team Foundation Server Proxy.

  2. Open Windows Explorer and locate the proxy installation directory.

  3. Open Proxy.config in a text or XML editor.

  4. Locate the <CacheRoot> element.

  5. Update the <CacheRoot> element by changing the current cache root folder location to the new location as follows:

    <CacheRoot>NewCacheRootFolderLocation</CacheRoot>
    
  6. Save and close the Proxy.config file.

    NoteNote:

    To maximize performance, copy the files from the old cache folder to the new cache folder.

  7. Open a Command Prompt window, type iisreset, and then press ENTER.

  8. Delete the old cache root folder.

    The default cache root folder is located at …\Program Files\Microsoft Visual Studio 2008 Team Foundation Server\Web Services\VersionControlProxy\Data.

To change the limit at which old files are removed from the cache

  1. On the Team Foundation Server Proxy computer, open Windows Explorer, and locate the proxy installation directory.

  2. Open Proxy.config in a text or XML editor.

  3. Locate the <CacheLimitPolicy> element.

  4. Select one of the following:

    • To specify a percentage of available disk space to fill before removing old files from the cache, update the <PercentageBasedPolicy> element.

      For example, the following line specifies that the cache should fill up to 60% capacity of available disk space before removing old files:

      <PercentageBasedPolicy>60</PercentageBasedPolicy>
      
    • To specify a fixed size in MB for the cache to reach before removing old files, add or update the <FixedSizeBasedPolicy> element.

      For example, the following line specifies that the cache should reach 500 MB before removing old files.

      <FixedSizeBasedPolicy>500</FixedSizeBasedPolicy>
      
    NoteNote:

    Both the <PercentageBasedPolicy> and <FixedSizeBasedPolicy> elements cannot be in effect at the same time.

  5. Save and close the Proxy.config file.

  6. Open a Command Prompt window, type iisreset, and then press ENTER.

To change the amount of cache to free when removing old files

  1. On the Team Foundation Server Proxy computer, open Windows Explorer, and locate the proxy installation directory.

  2. Open Proxy.config in a text or XML editor.

  3. Locate the <CacheDeletionPercent> element.

  4. Update the <CacheDeletionPercent> element by changing the percentage of cache space to free when you remove old files.

    For example, the following line specifies to free 50% of the cache when you remove old files.

    <CacheDeletionPercent>50</CacheDeletionPercent>
    
  5. Save and close the Proxy.config file.

  6. Open a Command Prompt window, type iisreset, and press then ENTER.

You can change the interval for saving cache performance statistics to an XML file that is named ProxyStatistics.xml. These statistics are tracked by performance counters that are installed by default. The ProxyStatistics.xml file is located in the App_Data folder in the proxy installation directory.

You can view these performance statistics from the Performance monitor or by using the ProxyStatistics Web service. For more information, see How to: Examine Cache Performance By Using Performance Monitor.

To change the interval for saving performance statistics to a file

  1. On the Team Foundation Server Proxy computer, open Windows Explorer, and locate the proxy installation directory.

  2. Open the Proxy.config file in a text or XML editor.

  3. Locate the <StatisticsPersistTime> element.

  4. Update the <StatisticsPersistTime> element by changing the number of hours for each interval.

    NoteNote:

    The default and minimum interval is 1 hour. The maximum interval is 24 hours.

    For example, the following line specifies that 2 hours should pass between saving the statistics to a file:

    <StatisticsPersistTime>2</StatisticsPersistTime>
    
  5. Save and close the Proxy.config file.

  6. Open a Command Prompt window, type iisreset, and then press ENTER.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.