Solved

Modify TEMP Location within a Terminal Service Session Win2000

Posted on 2004-04-02
2
280 Views
Last Modified: 2010-04-12
Gents

I have a problem with the Temp folder location for each of my users as they log into a terminal session.

It is that I cannot seem to modify the Environment path to show their "%homedrive%\%UserName%\Temp" on another server. Everytime they log on they get the local temp profile for the server they are on. This would not normally be a problem but we have roundrobin enabled so the user is not guaranteed to have the same temp folder when he logs on as we have 3 servers within this they have a 1 in 3 chance of getting the Temp folder with their files in.
I have heard that their maybe a registry hack for this but I cannot find it. also maybe it could be achieved through a logon script in VB as I have limited knowledge with VB I am not sure how toi progress this.

This is very important to me so I will award 500 points.

I will be very gratefull for any help on this

Regards

Darren
0
Comment
Question by:DarrenJackson
2 Comments
 
LVL 5

Accepted Solution

by:
visioneer earned 500 total points
Comment Utility
Here's how I've done it in the past and it's worked great.

Create a file with Notepad called ENVIRON.KEY and put it in your system32 directory, with the contents as follows:

HKEY_CURRENT_USER\Environment
    TEMP = REG_EXPAND_SZ %homedrive%\%UserName%\Temp
    TMP = REG_EXPAND_SZ %homedrive%\%UserName%\Temp
    TMPDIR = REG_EXPAND_SZ %homedrive%\%UserName%\Temp

Next, edit the logon script for your Terminal Server (I like to change the USRLOGON.CMD file in the system32 directory) and add this to the top of the script:

regini %windir%\system32\environ.key > nul

This will merge the registry settings for the temp folder location.  Note that this will take effect the NEXT time they log in, after this change has been applied.  However, once it is applied, it should stay that way.
0
 

Author Comment

by:DarrenJackson
Comment Utility
Many thanks for this visioneer. You are right it works a treat.

Thankyou very much

Darren
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Suggested Solutions

NTFS file system has been developed by Microsoft that is widely used by Windows NT operating system and its advanced versions. It is the mostly used over FAT file system as it provides superior features like reliability, security, storage, efficienc…
In this step by step tutorial with screenshots, we will show you HOW TO: Enable SSH Remote Access on a VMware vSphere Hypervisor 6.5 (ESXi 6.5). This is important if you need to enable SSH remote access for additional troubleshooting of the ESXi hos…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now