-
Loadrunner中进程和线程的概念中讲述了一件事实:作为一个线程比一个进程运行Vuser能更有效地使用内存。Loadrunner作为一个进程运行Vuser时为每个Vuser创建一个mmdrv.exe(多线程驱动进程,Multithreaded Driver Process)/mdrv.exe或者r3vuser.exe(仿真应用程序客户端,存在于Wlrun.exe中)进程,作为一个线程运行Vuser时为每个Vuser创建一个线程。mmdrv.exe是对mdrv.exe的封装,它被用做一些协议以更好的利用内存,mmdrv.exe实际上做了一些内存优化然后调用mdrv.exe。
-
HP LoadRunner软件系统要求中对内存要求隐约提到:At least 1 MB RAM per Vuser, depends on Vuser protocol environment。
网上提供了LoadRunner 9.1 Virtual User FootPrints,见下载1和下载2。
Mark Tomlinson在文How To: Understand and calculate Virtual User "footprint"给出了具体计算和考量方法。
【资源】
-
IP Wizard(位于%programfiles%\Mercury\LoadRunner\bin\ipwizard.exe)不支持DHCP分派的网络,见下图:
因此使用IP欺骗的客户机必须使用固定IP。它的设置能保存为.ips后缀的文件。
设置完毕后需要重启生效,见下图
在当前用户的Temp目录(位于%Temp%)分别生成unix_routing.sh和nt_routing.bat两个文件。
以下是生成的设置脚本:
nt_routing.bat
REM This is a bat file to add IP addresses to the routing table of a server
REM Replace [CLIENT_IP] with the IP of this machine (Load Generator) that the server already recognizes
REM This script should be executed on the server machine
route ADD 192.168.1.1 MASK 255.255.255.255 [CLIENT_IP] METRIC 1
unix_routing.sh
# Bourne shell script to add IP addresses to the routing table of a server
# To run replace [CLIENT_IP] with the IP of this machine (Load Generator) that the server already recognizes
# Then chmod +x unix_routing.sh
# and finally execute this script on the server
#!/bin/sh
route add 192.168.1.1 [CLIENT_IP] 255.255.255.0
IP欺骗设置生效后,如要使用它需要勾选LoadRunner Controller菜单Scenario->Enable IP Spoofer。此后在LoadRunner Controller勾选菜单Tool->Export Mode,再打开菜单Tool->Options->General,能看见Multiple IP address Mode有效。
【资源】
-
从TCPView中能看到:

从HP LoadRunner Controller User's Guide和LoadRunner Architecture中知道,LoadRunner Controller与Load Generator间相互通信的端口号:
By default, the LoadRunner Controller uses TCP port 50500 to send data to TCP port 54345 on the Windows Load Generator.
附录:常用网络通讯端口
Protocol Type
Port
Description
UDP
20
FTP data transfer
TCP
21
FTP commands
TCP
22
SSH
TCP
23
Telnet
UDP
53
DNS Queries
TCP
53
DNS Zone transfers
TCP
80
HTTP
TCP
110
POP3
TCP
111
Monitor Solaris
TCP
135
Microsoft Remote Procedure Call (RPC) service
UDP
137
NetBios Name Service
UDP
138
NetBios datagram,used by Windows(and services on UNIX like SAMBA)
TCP
139
Monitor Windows
TCP
139
NetBios Session Service used for resource sharing on Windows
UDP
161
SNMP for agent
UDP
162
SNMP for manager
TCP
443
HTTPS
TCP
445
Microsoft-DS Service used for resource sharing on Windows
TCP/UDP
1521
Oracle
TCP
3389
Microsoft Remote Desktop sessions use
TCP
8888
SiteScope
TCP
50000
DB2 on Windows
TCP
50500
LoadRunner Controller communicates to LoadRunner Generator/Agent(Windows)
TCP
54345
LoadRunner Generator/Agent communicates to LoadRunner Controller(Windows)
TCP
60000
DB2 on Unix
详见PORT NUMBERS。
-
LoadRunner监听相关的KB:
Solution: Set up the correct timeout value
This error indicates that the page download timeout limit specified is reach. If you need to increase this limit, however,
For LoadRunner 7.6 or above:
1. Go to Run-Time settings
2. Go to Internet Protocol:Preferences -> Select 'Options' button
3. Change the 'Step DownLoad Timeout' from default value form 120 to any desired value
Prior to LoadRunner 7.6:
1. Go to Run-Time settings
2. Under Browser Emulation -> Select 'Options' button
3. Change the 'Step DownLoad Timeout' from default value form 120 to any desired valuePlease note that on the Run-Time Setting's UI, the maximum limit for step download timeout is 32000 seconds. If you need to increase this limit, however, use the web_set_timeout() function.
Example:
web_set_timeout(STEP, "xx"); //for regular web Vuser
web.set_timeout(STEP, "xx"); //for regular Java / JavaScript VuserThe Step Download Timeout encompasses all requests made from a single LoadRunner statement. For example, a step in the script may consist of a single request to the server, or may consist of 10 requests. A good example of this would be a statement in HTML mode. Take as an example the following:
An HTML mode web_url to www.google.com would consist of a request to the Google server for the main HTML file. After parsing this HTML file, you will find two additional resources to download (two .gif files). In HTML mode, these resources are downloaded automatically as a part of the web_url for www.google.com. Thus, the Page Download Timeout will encompass all three requests.
Solution: WinINet uses the Microsoft interface to the internet
Starting with version 7, LoadRunner uses Sockets mode replay by default. This was also known as Turbo replay. Socket/Turbo replay utilizes its own interface to the network card. This proprietary replay engine is a lighter engine that is scalable for load testing.
The older WinInet replay, which can be enabled in LoadRunner by selecting "WinInet replay instead of Sockets (Windows only)", uses the Microsoft WinInet DLL to talk to the network card. The limitations of the WinInet replay engine are that it is not scalable, nor does it support UNIX. In addition, when working with threads, the WinInet engine does not accurately emulate the modem speed and number of connections. However, The WinInet is the engine used by Internet Explorer. It supports all of the features incorporated into the Internet Explorer, and thus, WinInet replay can resolve some replay errors.
Problem Description: Web replay hangs after receiving the HTTP header information
When requesting a header for a page using the HEAD method, the script's replay hangs after receiving the header information.
Diagnosis: By default, Web replay uses socket mode replay that checks the value of the "Content-Length" header. If it is suppose to receive more data, the replay will wait/hang until time-out.
参考资料:
¡ Troubleshoot a Windows bluescreen, a.k.a bugcheck, a.k.a blue screen of death
¡ 开源Proxy程序,类似LoadRunner的VuGen
¡ LoadRunner进行Web测试时吞吐量和点击量深入研究
¡ Performance Tool Comparison: How LoadRunner,OpenSTA and JMeter stack up at runtime -1、2


