Windows limitation of maximum path length on the temporary directory of Performance Center load generator
Problem
When running VuGen scripts in Performance Center and the following error appears:
"Error: The user files were not transferred to the local load generator."
Cause
The controller cannot transfer the script files to the Load Generator.
When running a scenario in LoadRunner Controller / Performance Center, the Controller transfers the Vugen script files to the temporary location on the Load Generators. The temporary location will be created under <the load generator’s temporary directory>\<brr folder>\netdir\<Path to the results folder on the controller>\<results name>.
For example, if the script in Controller is stored in c:\VugenScript\Script1 and the Load Generator has the temporary folder set to C:\Documents and Settings\Default User\Local Settings\Temp, the Load Generator would save this script file in C:\Documents and Settings\Default User\Local Settings\Temp\<brr folder>\netdir\c\VugenScript\Script1.
This is caused by a limitation of the maximum path length on Windows OS. The length limitation is 255 bytes in Windows XP and 260 bytes in Windows Vista. Please refer to MSDN: File Names, Paths, and Namespaces(http://msdn.microsoft.com/en-us/library/aa365247(VS.85).aspx) for more details on this limitation.
Fix On the Load Generator:
A. If you are running the agent as a process, you can change the "TEMP" system Variable of the user from C:\Documents and Settings\Default User\Local Settings\Temp to C:\Temp.
B. If you are running the agent as a service, you can change the service to use an account with Administration privileges, and change the admin account’s "TEMP" system variable to a shorter path:
- Go to Start -> Control Panel -> Administrative Tools -> Services.
- Look for the LoadRunner / Performance Center Agent Service.
- Right-click and select Properties->Log On, changing this from "Local System account" to "This account", supplying the Administrative account username and password.
- To change the admin user temporary location is described below:
How to set the system’s TEMP and TMP directories
Changing the system’s temporary directories
To create a temporary directory:
1. Bring up Windows Explorer, find a drive that has sufficient space.
2. If TEMP folder does not exits, create a directory called "TEMP" in the root location of the drive.
Example: C:\TEMP
To add/change the temporary environemnt:
1. For Windows 2000 or Windows XP machine:
a. Right-click on the ‘My Computer’ icon on the desktop and select ‘Properties’.
b. Go to the Advanced tab and click on the ‘Environmental Variables’ button.
c. There are two sections listed: User Variables and System Variables. Under each section, you should see a variable for TEMP and TMP.
d. Double-click on these entries, and modify the location to the temporary environment created above.
Example:
Change from C:\Documents and Settings\<user>\Local Settings\Temp
Change to C:\TEMP
e. Click <Apply>.
2. For Windows NT machine:
a. Right-click on the ‘My Computer’ icon on the desktop and select ‘Properties’.
b. Go to the ‘Environmental’ tab.
c. There are two sections listed: User Variables and System Variables. Under each section, you should see a variable for TEMP and TMP.
d. Double-click on these entries, and modify the location to the temporary environment created above.
Example:
Change from C:\Documents and Settings\<user>\Local Settings\Temp
Change to C:\TEMP
e. Click <Apply>.
Thanks for the valuable information.
ReplyDelete-Naresh