How to Move the TEMP and TMP Directories
The Microsoft Exchange Information Store service uses the TEMP and TMP folders as temporary storage during various operations, such as message conversion and mailbox move operations. The TEMP and TMP environment variables are used to designate which folders in the file system (e.g., which path) should be used by applications that require a temporary workspace. TEMP is typically used by applications, such as Microsoft Exchange and TMP is typically used by development tools, such as Microsoft Visual C++. The path for each variable is usually relative to the security context of the application or tool.
On a non-clustered Exchange server, the Exchange store uses the SYSTEM (e.g., Local System) which uses a default environment variable setting of %Systemroot%\Temp for both TEMP and TMP. Exchange Virtual Servers running in a Windows Server cluster use the environment variable settings for the Cluster Service account, which runs under the context of a specific user security principle. For user accounts, the default environment variable for TEMP and TMP is set to %Userprofile%\Temp.
This topic explains how to move the TEMP and TMP directories in clustered and non-clustered environments.
Before You Begin
Before you perform the procedures in this topic, consider the following recommendations:
For optimal performance, it is recommended that you do not use the disk containing the operating system for the TEMP and TMP folders used by Exchange. In addition, you should ensure that these environment variables are set to paths on a fast disk or disk subsystem, such as a RAID 0+1 spindle set.
It is recommended that you do not use the disk containing the operating system for the TEMP and TMP folders used by Exchange or Exchange Virtual Servers.
Procedure
To move the TEMP/TMP folders in a non-clustered environment
Log on to the Exchange server computer with an account that has administrative rights.
Right-click My Computer and select Properties.
Select the Advanced tab.
Click the Environment Variables button.
In the System variables area, select TEMP and click the Edit button.
In the Variable value field, enter the new path for the TEMP environment variable and click OK.
In the System variables area, select TMP and click the Edit button.
In the Variable value field, enter the new path for the TMP environment variable and click OK.
Click OK to close the Environment Variables dialog box and OK once more to close the System Properties dialog box.
Reboot the server to apply the change.
To move the TEMP/TMP folders in a clustered environment
Log on to a node in the cluster as the Cluster service account.
Right-click My Computer and select Properties.
Select Advanced.
Click Environment Variables.
In the User variables for <account name> area, select TEMP and click Edit.
In the Variable value field, enter the new path for the TEMP environment variable and click OK.
In the User variables for <account name> area, select TMP and click Edit.
In the Variable value field, enter the new path for the TMP environment variable and click OK.
Click OK to close the Environment Variables dialog box and OK once more to close the System Properties dialog box.
Restart the node to apply the change.
Repeat steps 1 through 10 for each node in the cluster.