Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Loadrunner self-study and question answer 1

2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

Video summary home page: https://edu.51cto.com/lecturer/4626073.html

1. The solution if the LR script is empty:

Remove the third-party support from the ie setting and cancel it.

In system Properties-Advanced-performance-data execution Protection, add the vugen.exe file in the loadrunner installation directory.

It may be due to the problem that the recorded URL address is localhost. Change it to the assigned IP address or 127.0.0.1.

2. When inserting a text checkpoint step, you use web_reg_find, which usually contains double quotation marks in TextPfx and TextSfx, which need to be escaped (with slashes), for example:

Web_reg_find ("Search=Body"

"SaveCount=Welcome"

"TextPfx= Welcome"

"TextSfx="

LAST)

3. Why doesn't the IE browser pop up when LoadRunner records the script?

When multiple browsers are installed on a host, LoadRunner recording scripts often encounter situations in which the browser cannot be opened, which can be solved in the following ways.

Launch the browser, open the Internet options dialog box, switch to the advanced tab, uncheck "enable third-party browser extensions (need to restart)", and then run VuGen again to solve the problem.

Tip: usually after installing browsers such as Firefox, you will check the above options, resulting in non-normal recording. Therefore, it is recommended to maintain a clean test environment on the host running LoadRunner.

4. What's the difference between HTML-based script and URL-based script scripts?

The script is recorded in "HTML-based script" mode, and VuGen generates separate steps for each HTML operation of the user. This script looks intuitive.

When you record a script using "URL-based script" mode, VuGen can capture all HTTP requests sent to the server as a result of a user's action, and then generate a corresponding method for each user's request.

Usually, browser-based Web applications use "HTML-based script" mode to record scripts, while there are no browser-based Web applications, Web applications contain Java Applet to interact with the server, browser-based applications contain JavaScript/VBScript code to communicate with the server, and browser-based applications use HTTPS security protocol to record.

5. What is the main impact of runtime Pacing settings?

Pacing is mainly used to set the interval between iterating scripts. There are three ways:

A: start immediately after the end of the last iteration, B: wait for a fixed time after the end of the last iteration, and C: start the new iteration at fixed or random intervals.

You can set iterations according to your actual needs. Usually, there is no time interval will lead to more stress.

6. In the runtime setting Log tag, if "Enable logging" is not checked, can manual messages be sent?

The Enable logging option affects only automatic logging and messages sent over lr_log_message. Even if it is not checked, if lr_message, lr_output_message, lr_error_message are used in the virtual user script, the messages they send will still be recorded.

7. Does VuGen support Netscape's customer certificate?

Not supported. Only client certificates for Internet Explorer are supported in the current VuGen version 8.0. When you record a script, you can first export the required certificates from Netscape, then import them into Internet Explorer, and ensure that they are exported and imported in the same order. Also, repeat the previous process on each computer that will record or run a Web Vuser script that requires a certificate.

8. Will VuGen modify the proxy server settings in the recording browser?

Will be modified. When you start recording a browser-based Web Vuser script, VuGen first launches the specified browser. VuGen then instructs the browser to access the VuGen proxy server. To do this, VuGen modifies the proxy server settings on the recording browser. By default, VuGen immediately changes the proxy server setting to Localhost:7777. After recording, VuGen restores the original proxy server settings to the recording browser. Therefore, you cannot change the proxy server settings while VuGen is recording, otherwise it will not work properly.

9. How does the LoadRunner script output the current system time?

LoadRunner provides a char * ctime (const time_t * time) function, which calls an integer pointer with a long parameter to store a numerical representation of the return time.

The invocation statement and the return value are as follows:

Typedef long time_t

Action ()

{

Time_t t

Lr_message ("Time in seconds since 1-1-70:% ld\ n" time (& t))

Lr_message ("System time and date:% s", ctime & t)

}

The output is as follows:

Time in seconds since 1-1-70: 1185329968

System time and date:Wed Jul 25 10:19:28 2007

10. There is no problem with the playback of some Web virtual user scripts immediately after recording, but if the number of iterations is greater than 1, you can only iterate successfully once. Why did the error occur from the second iteration?

This phenomenon is mostly due to the fact that in the "Browse Emulation" setting of "Run-time Setting", check "Simulate a new user on each iteration" and the following option "Clear cache on each iteration". These two options mean to simulate a new user for each iteration and clear the cache for each iteration.

Because init and end can only be executed once during script iterations, if each iteration simulates a new user and clears the cache, the user login information will be cleared along with it, so errors may occur during the iteration.

11. What is the difference between threads and processes running in the virtual client script "Run-time Setting"?

If you select "Run Vuser as a process", the scene runtime will create a process for each virtual user; select "Run Vuser as a thread" to run each virtual user as a thread and see only one mmdrv.exe in the task manager, which is more efficient and more stressful, the default option.

In addition, if IP spoofing is enabled, select "Expert Mode" under the Tools menu in Controller, and then set the IP address allocation method in the "Options > General" tab under the Tools menu to be consistent with the way Vuser runs, with thread or process mode.

12. When running Web-related test scenarios in Controller, there are often a lot of timeout errors. How to deal with such problems?

This is mainly caused by the default timeout setting of the script. When playing back the Web script, sometimes a timeout error occurs due to the long response time of the server. At this point, you need to modify the runtime configuration of the script.

After entering the "Run-time Setting" dialog box, enter "Internet Protocol → Preference". Then click "Options..." Button to enter the Advanced Settings dialog box, you can modify the default values of various timeout settings.

13. Why is it that the CPU, memory and other resources in the Windows system are still sufficient, but the number of simulated users cannot go up to-27796?

Under the standard setting of Windows computers, the default limit of the operating system is only a few hundred Vuser, which has nothing to do with CPU or memory, mainly because the operating system itself specifies a default maximum number of threads. If you want to break the Windows limit, you must modify the Windows registry. Take Windows XP Professional as an example.

(1) after opening the registry, enter the following keywords in the registry key HKEY_LOCAL_MACHINE: System\ CurrentControlSet\ Control\ Session Manager\ SubSystems.

(2) find the Windows keyword, and the Windows keyword is as follows:

% SystemRoot%\ system32\ csrss.exe bjectDirectory=\ Windows

SharedSection=1024,3072512 Windows=On SubSystemType=Windows ServerDll=basesrv,1

ServerDll=winsrv:UserServerDllInitialization,3 ServerDll=winsrv:ConServerDllInitialization,2

ProfileControl=Off MaxRequestThreads=16

The format of the SharedSection=1024,3072512 keyword is xxxx,yyyy,zzz. Where xxxx defines the maximum value of the system-wide heap in KB, and yyyy defines the size of each desktop heap.

(3) change the setting of yyyy from 3072 to 8192 (that is, 8MB) and increase the value of SharedSection parameter.

By making changes to the registry, the system will allow more threads to run, so more Vuser can be run on the computer. This means that the maximum number of concurrent users that can be simulated will not be limited by the Windows operating system, but only by hardware and internal scalability restrictions.

14. Error-27728: the solution of Step download timeout (120seconds)

Loadruner error: Error-27728: Step download timeout (120seconds) how to solve the syntax check pass, but in the concurrent execution of a query Action.c (16): Error-27728: Step download timeout (120seconds) has expired when downloading non-resource (s), excuse me what solution, I use web_set_timeout, does not seem to work, directly set the timeout time in option to 600, (unit should be seconds) or did not work The result is still a 120seconds, which means that it is judged by 120 seconds. Using lrs_set_recv_timeout, syntax checking however indicates that there is no such function in the library function. Try step: set the timeout to 600 seconds, playback or error. Later, I set a winlnet replay instead of sockets option in the advaced area of internet protocol-preferences in runt time setting, and then playback is successful.

First of all, LR records the web protocol through Microsoft WinInet DLL! But when Control is running, it uses socket to simulate the request by default, because these can simulate the real bandwidth, while using Microsoft WinInet DLL to access the network card through this DLL to simulate the bandwidth, so the simulation is not very accurate! And it does not support the application of unix, but it is sometimes impossible to handle some requests of winnet Dll. I think it is some of its BUG, for example: it checks Content-Length during playback, but when the web page supports receive more data, the socket simulation will wait until timeout! First I talked about some advantages and disadvantages, and finally I came back to this question! This problem is analyzed in two aspects:

First: you need to understand the scope of the web_set_timeout () function! For example, a web_submit_data () actually covers 10 requests to the Server side, and this function is for the total time of 10 requests! (don't make low-level mistakes, timeout is divided into three parts: connect,receive and download:) second: I explained some of the above BUG problems! WinInet dll can handle requests asynchronously in the new version, but it is no longer the connection wait-and-time-out mode! But the socket used by LR is a synchronous request! You won't quit until timeout! Microsoft has made it clear that INTERNET_OPTION_RECEIVE_TIMEOUT is no longer applicable to Microsoft Internet Explorer 5.0, and it is clear that they handle requests asynchronously! He he! This will probably fully explain your problem! Ha ha. Here.

I add as follows: VuGen-specific socket-based replay is a lightweight engine that scales for load testing. It is accurate when using threads. Socket-based engines do not support socks proxy servers. If you are recording in such an environment, you should use the winInet replay engine.

15. Performance testing often requires the preparation of large quantities of data. There are many ways to generate large quantities of data. The common ones are:

(1) write SQL statements to insert data

(2) use professional data generation tools such as DataFactory.

(3) generate large quantities of data repeatedly by recording and playback in LoadRunner

Tips:

Null values will occur when inserting data of nchar data type using DataFactory. You can modify the data type setting of the database first, and then change it back after inserting the data.

16. The recording script contains Chinese, what if there is garbled code?

Select UTF-8 for Support charset in the recording options

After recording the script, switch to the tree view and open the appropriate script page. The script recorded in the PageView on the right presents the Chinese layout, but when you switch to Server Response, all the Chinese characters are replaced with garbled codes, such as "Mulao".

The reason is that the server did not set the encoding of the response to gb2312.

Find the Web.Config file in IIS and find it in … . After joining the section, record the script again and change the random code into Chinese.

When 17.LoadRunner plays back the script, the Chinese displayed in the browser is garbled.

Solution (1):

First set Run-Time Settings-Browser-Browser Emulation-User-Agent

Then set the IE:

View-encode-hook "Auto Select" and Unicode (UTF-8).

Solution (2):

Use the lr_convert_string_encoding function to convert the code

Here is an example of use:

Lr_convert_string_encoding (lr_eval_string ("{ReplyContents}"), LR_ENC_SYSTEM_LOCALE,LR_ENC_UTF8, "ReplyMessage")

Web_submit_data ("postreply.aspx_2"

"Action= http://127.0.0.1/postreply.aspx?infloat=1&topicid=2&&inajax=1",

"Method=POST"

"EncType=multipart/form-data"

"RecContentType=text/xml"

"Referer= http://127.0.0.1/showtopic-2.aspx",

"Snapshot=t9.inf"

"Mode=HTML"

ITEMDATA

"Name=iconid", "Value=0", ENDITEM

"Name=title", "Value=", ENDITEM

"Name=wysiwyg", "Value=0", ENDITEM

"Name=checkbox", "Value=0", ENDITEM

"Name=message", "Value= [localimg = 180112] 1 [/ localimg]\ r\ n\ n {ReplyMessage}", ENDITEM

"Name=e_mediatyperadio", "Value=on", ENDITEM

"Name=sl_attachdesc", "Value=", ENDITEM

"Name=attachid", "Value=", ENDITEM

"Name=attachdesc", "Value=", ENDITEM

"Name=localid", "Value=", ENDITEM

"Name=attachdesc", "Value=", ENDITEM

"Name=localid", "Value=1", ENDITEM

"Name=attachdesc", "Value=", ENDITEM

"Name=localid", "Value=2", ENDITEM

"Name=emailnotify", "Value=on", ENDITEM

"Name=postreplynotice", "Value=on", ENDITEM

"Name=postfile", "Value=", "File=Yes", ENDITEM

"Name=postfile", "Value=D:\ picture collection\ It's about time.JPG", "File=Yes", ENDITEM

"Name=postfile", "Value=", "File=Yes", ENDITEM

"Name=uploadallowmax", "Value=10", ENDITEM

"Name=uploadallowtype", "Value=jpg,gif", ENDITEM

"Name=thumbwidth", "Value=300", ENDITEM

"Name=thumbheight", "Value=250", ENDITEM

"Name=noinsert", "Value=0", ENDITEM

LAST)

18. You can find the parameter file in the directory of the LR test script, and modify the parameter file directly

The parameter file is stored in the script directory as .dat file extension. It can be opened with a simple text editor like Notepad as it is stored in pure text format. Therefore, you can manipulate the files via the Notepad. You can also use office applications such as Microsoft Excel or OpenOffice.org Calc to work on the file. This greatly the amount of work required for maintaining a long list of data.

19.LR9.x prompts "Failed to connect to server" when starting VUGen

After upgrading to LoadRunner 9.x I started getting a window popup which said "Failed to connect to server" every time I opened virtual user generator (vugen.exe).

The solution to this was to close virtual user generator and delete the [vugen.ini] file.

Vugen.ini is found in the% systemroot% folder on your Windows PC (usually C:\ WINDOWS or C:\ WINNT).

Once you've deleted the file, virtual user generator will open without any issues and create a new vugen.ini file automatically.

20. How to grab a dynamic value with the same left and right boundaries?

How to grab a dynamic value with the same left and right boundaries? For example:

StateID= "d7lg0ehmjkkm6uin3s4boei7oq" >

StateID= "cvopakp46ftsf8mh7l37ti3ubm" >

StateID= "bv9mja8gtgr39ddibm5t9163re" >

How should the ORD in web_reg_save_param be set?

ORD: Indicates the ordinal position or instance of the match. The default instance is 1. If you specify "All," it saves the parameter values in an array.

Example:

Char outFlightParam [50]; / / The name of the parameter for correlation

Char outFlightParamVal [50]; / / The formatted value of outFlightParam

Web_reg_save_param ("outFlightVal"

"LB=outboundFlight value=", "RB= >"

"ORD=ALL"

"SaveLen=18"

LAST)

Web_submit_form ("reservations.pl"

"Snapshot=t4.inf"

ITEMDATA

"Name=depart", "Value=London", ENDITEM

"Name=departDate", "Value=11/20/2003", ENDITEM

"Name=arrive", "Value=New York", ENDITEM

"Name=returnDate", "Value=11/21/2003", ENDITEM

"Name=numPassengers", "Value=1", ENDITEM

"Name=roundtrip", "Value=", ENDITEM

"Name=seatPref", "Value=None", ENDITEM

"Name=seatType", "Value=Coach", ENDITEM

"Name=findFlights.x", "Value=83", ENDITEM

"Name=findFlights.y", "Value=16", ENDITEM

LAST)

Sprintf (outFlightParam, "{outFlightVal_%s}"

Lr_eval_string ("{outFlightVal_count}"))

Sprintf (outFlightParamVal, "Value=%s"

Lr_eval_string (outFlightParam))

Lr_message ("The value argument is:% s", outFlightParamVal)

Web_submit_form ("reservations.pl_2"

"Snapshot=t5.inf"

ITEMDATA

"Name=outboundFlight", outFlightParamVal, ENDITEM

"Name=reserveFlights.x", "Value=92", ENDITEM

"Name=reserveFlights.y", "Value=10", ENDITEM

LAST)

21. Prompt "Step download timeout (120seconds) has expired when downloading resource (s)" when running the scene

Vuser_init.c (12): Error-27728: Step download timeout (120seconds) has expired when downloading non-resource (s) (individual cases can be ignored)

Vuser_init.c (12): Error-27727: Step download timeout (120seconds) has expired when downloading resource (s). Set the "Step Timeout caused by resources is a warning" Run-Time Setting to Yes/No to have this message as a warning/error, respectively

Vuser_init.c (12): Error-27796

If it is not an error to download a page for more than 2 minutes, you can select Preferences- > Options in the Run-Time setting to modify the time of Step download timeout (sec).

Or set "Step timeout caused by resources is a warning" to Yes, so that the download resource timeout is only as a warning, not as an error prompt, but for non-resource download timeout, it will always prompt an error.

twenty-two。 Using strtok function to split strings

You need to get "15" (the red highlight below) in the loadrunner and make the associated parameters.

/ / Body response content: / / OK [8, 7, 5, 15, 6, 0, 0, 4, 0, 0, 0, 4, 0, 0, 4, 0, 4, 0, 4, 4, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4

Use web_reg_save_param to take out the paragraph "8, 7, 5, 15, 6, 5, 0, 0, 0, 0, 0, 3, 2, 0, 0, 0, 0, 0, 1", then use the strtok function to cut out the numbers, and the fourth number is the value you are looking for.

For example:

Extern char * strtok (char * string, const char * delimiters); / / Explicit declaration

Char separators [] = ","

Char * token

Lr_save_string ("1, str, 2, 3, 4, 5, 6")

Token = (char *) strtok (lr_eval_string ("{str}"), separators); / / Get the first token

If (! token) {

Lr_output_message ("No tokens found in string!")

Return (- 1)

}

While (token! = NULL) {/ / While valid tokens are returned

Lr_output_message ("% s", token)

Token = (char *) strtok (NULL, separators); / / Get the next token

}

23.LoadRunner does not buy license of webservice protocol, but only http. Can webservice be simulated completely with http protocol?

Yes, refer to:

Http://blog.testsautomation.com/2009/01/web-services-performance-using-loadrunner/

Http://blog.testsautomation.com/2009/05/validating-web-service-response-with-xpath/

24. Think time is not ignored in the scenario settings, but how can LR automatically subtract think time from the response time when looking at the response time?

Find the setting in analysis whether to make the appropriate setting in the place where the thinking time is included in the report:

25.LoadRunner stops one and a half virtual users during operation.

Another issue that I'm facing from time to time is that LoadRunner stops 50% of running users without any notification, issue, error message etc. I've find out that it happens only when running with log level set to 'always send a message'. Because of that, I suggest to run with log level set to 'Send message only when error occur'.

twenty-six。 Which protocol should be selected for recording in LoadRunner to test the RTMP protocol?

Using flex protocol

There are several functions available:

Flex_rtmp_connect Connects a client to an RTMP server and sets connection options.

Flex_rtmp_disconnect Disconnects a client from an RTMP server.

Flex_rtmp_send Sends messages to an RTMP server.

Flex_rtmp_receive Receives responses from an RTMP server

Flex can record and replay scripts involving RTMP (Real Time Messaging Protocol). In order to enable RTMP simulation, you must configure the recording options for the Flex protocol.

To enable RTMP:

1 Open the Recording Options dialog box by selecting Tools > Recording Options or clicking the Options button in the Start Recording dialog box.

2 In the Network > Port Mapping node click Options.

3 Set the Send-Receive buffer size threshold to 1500.

twenty-seven。 How do I run a QTP script in LoadRunner?

1. Operation preparation:

1) check the "Alow other Mercury products to run tests and components" of QTP's Tools--Options--Run

2) record the QTP script that needs to be run in lr, and set the transaction in the QTP script, Services.StartTransaction "start" and Services.EndTransaction "start"

2. Run the QTP script

When running in LR, select the QTP script to store the file with the .usr extension in the directory for the QTP script.

Note: when running a QTP script in LR, there can be only one Vuser, otherwise an error will be reported:

The load generator is currently running the maximum number of Vusers of this type

twenty-eight。 How to ignore the verification of data received by Socket in LR

When testing the performance of Socket in LR, LR will determine the length of the data returned by lrs_receive, and if the length does not match, there will be a time delay (which is totally unacceptable for performance testing). If this is done, a simple method (using * instead of specific length) is found after repeated attempts:

Similar to setting:

Recv buf1 12

"Hello, Denny"

Change to:

Recv buf1 *

"Hello, Denny"

Everything OK.

Apache monitoring cannot be added to the Controller of 29.LoadRunner9.5

Find the online_resource_graphs.rmd file in C:\ Program Files\ HP\ LoadRunner\ dat\ online_graphs and change the EnableInUI in the [Apache] section to 1

Reference:

Http://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1274450165814+28353475&threadId=1229523

30.VB Vuser develops an ADO script that prompts "user-defined type not defined"

Want to write the process of simulating data operations in VB Vuser, and then define this global variable in VB Vuser

Private m_Conn As ADODB.Connection 'connection object

Private m_Reco As ADODB.Recordset 'result set

But this object is not recognized in VB Vuser and user-defined type not defined is reported.

You need to select the library of ADO in the VBA section of the Run-Time settings.

If you use VBScript virtual users to develop, you can just use CreateObject to create ADO objects.

Error occurred while recording script in 31.loadrunner9.5 c:\ PROGRA~1\ MICROS~1\ office12\ Grooveutil.DLL memory location access is invalid

Problem with Office2007, IE add-in disables Groove GFSBrowser Helper component

How to modify the port number of the example that comes with 32.LR?

The example port number that comes with LR is 1080. How can I set the port number 8088 that I want to use, where to set it in the LR installation directory, find the Xitami.config file, find portbase, and modify it (default is 1000).

The default port number is portbase+80;. If you want to change the port number to 8088, change portionbase to 8008 and save it (8088 / 8008 / 80).

thirty-three。 Cannot find Chinese string when using Web_reg_find

There is a default.cfg in the script file, and the parameter is UTF8InputOutput. Change its value to 0.

thirty-four。 A script that replaces IP Wizard

Http://hi.baidu.com/higkoo/blog/item/39bbb21bc33d76dcac6e751c.html

The "IP Wizard" that comes with LoadRunner is very troublesome to use, and the important thing is that you have to restart the system to take effect at last.

So write a script instead:

1. Suppose the client IP is 192.168.10.31

two。 Suppose the server IP is 192.168.10.10

3. The IP to be simulated is 110.119.120.122

Then, the client provides a BAT script to add a virtual IP:

Netsh interface ip add address Local connection 110.119.120.122 255.255.0.0

The corresponding deletion settings are:

Netsh interface ip del address Local connection 110.119.120.122

Shell script for adding virtual routes to the corresponding server:

Route add-host 110.119.120.122 gw 192.168.10.31

Delete the script for the route:

Route del-host 110.119.120.122 gw 192.168.10.31

This is very convenient, no need to restart any machine, the execution of the script will take effect, and then execute the script will be cancelled.

thirty-five。 How do I invoke a LoadRunner script from the command line?

Here is the command line that you need to execute to run a VuGen script from the command prompt:

\ bin\ mmdrv.exe-usr

Note:

In order to get all the other options that go with the command, run mmdrv.exe from the command prompt without any options.

thirty-six。 I would like to ask "how to express the type of int64 in LR". I put a piece of C code in LR, LR does not recognize the type of int64, how to solve it?

Make that C code into DLL, and then call it in LR

37.LoadRunner monitors remote machine Windows resources, prompting "net use failed"

Solution:

Change the sharing and security mode of the local account to classic mode on the monitored machine. Control Panel-> Administrative tools-> Local Security Policy-> Network access: sharing and Security Mode of Local accounts-> Classic Mode.

Monitor preparations before connecting:

First of all, make sure that the monitored windows system opens the following two services, Remote Procedure Call (RPC) and Remote Registry Service

Monitored WINDOWS machine: right-click my computer, select manage-> shared folder-> share in this must have C$ this shared folder, (if not manually added)

Then make sure to run it on the machine where LR is installed. Enter\\ monitored machine IP\ C$ and then enter the administrator account number and password. If you can see the C disk of the monitored machine, it means that you have the administrator permission of that machine and can use LR to connect.

There is a garbled problem in the 38.LoadRunner script. If a link or picture name is garbled in Chinese, the script cannot be run.

Error analysis

Script recording may be in URL-based script mode, and if the set of characters defined by the program uses international standards, the script will garbled.

The solution is to re-record the script. Before recording the script, open the recording options configuration dialog box to set it, select "Surport Charset" in the "Advanced" option of "Recording Options", and then select the option that supports "UTF-8".

39.LoadRunner does not check the method error inserts the function Web_find in the script, sets the checkpoint of text and image in the script, but does not check the set checkpoint during playback, that is, Web_find is invalid.

Error analysis

Because the check function consumes some resources, LoadRunner turns off the protection check of text and image data by default, so after setting the checkpoint, you need to turn on the check function.

The solution opens the runtime environment settings dialog box for settings, and in the "Internet Protocol" option of "Run-time Settings", check the "Enable Image and text check" option under "Check" in "Perference".

It is important to note that errors in playback scripts are sometimes caused by the program itself, so you must ensure that the script recorded by the program is correct before solving the script playback problem.

40.LoadRunner timeout error: timeout often occurs during recording and playback of Web protocol scripts, and there are many reasons for the error, and the solutions are also different.

Error phenomenon 1:Action.c (16): Error-27728: Step download timeout (120seconds) has expired when downloading non-resource (s).

Error analysis: for HTTP protocol, the default timeout is 120 seconds (which can be modified in LoadRunner). The client sends a request to the server. If the server does not return a result after 120 seconds, a timeout error occurs.

Solution: first of all, set the timeout in the running environment, the default timeout can be set longer, and then set multiple iterations to run. If there is a timeout, you need to set a "winlnet replay instead of sockets" option in the "Runtime Setting" > "Internet Protocol:Preferences" > "Advanced" area, and then whether the playback is successful.

Error phenomenon 2:Action.c (81): Continuing after Error-27498: Timed out while processing URL= http://172.18.20.70:7001/workflow/bjtel/leasedline/ querystat/ subOrderQuery.do

Error analysis: this error is often caused by too much concurrent pressure, and the server is too busy to respond to client requests in time, so this error is normal and is caused by excessive pressure.

If the problem occurs when the pressure is low, there may be an error somewhere in the script. Take a closer look at the script and the error message will locate the location of a specific problem.

Solution: for example, if the above error problem is located on a URL, you need to run the scenario again and access the URL on other machines. If it cannot be accessed or takes too long, the server or this application may not be able to support such a heavy load. Analyze the server and it is best to optimize its performance.

If there is a timeout after running the scene again, you should analyze the reason in various graphics, for example, you can see if there is a problem with the server, DNS, network, and so on.

Finally, increase the runtime timeout setting. In "Run-Time Settings" > "Internet Protocol:Preferences", click "options" and increase the value of "HTTP-request connect timeout" or "HTTP-request receive".

Garbled code appears in 41.LoadRunner script: Chinese garbled code occurs when recording Web protocol script, which stops playback in garbled position when playback the script, and the script cannot be run.

Error: a link or picture name is garbled in Chinese, and the script cannot be run.

Error analysis: script recording may use URL-based script mode, if the set of characters defined by the program uses international standards, the script will garbled.

Solution: re-record the script, before recording the script, open the recording options configuration dialog box to set it, select "Surport Charset" in the "Advanced" option of "Recording Options", and then select the option that supports "UTF-8".

42.LoadRunner HTTP server status code: in the process of recording Web protocol script playback script, the HTTP server status code will appear, such as common page-404 error message,-500error message.

Error 1 the Not Found server did not find a resource that matches the requested URI, but can continue to run until the end.

Error analysis: the resources that match the request URI have already been submitted once when recording the script. The same resources must not be submitted repeatedly during playback, but the content of the submitted resources needs to be changed. Each time the script is played back, the submitted data will be changed to ensure that the actual environment is simulated, resulting in a certain load pressure.

Solution: correlate the script where the error occurs and insert the appropriate function if necessary.

Error phenomenon 2 internal error in the Internal Server Error server, script execution stops.

Error analysis: the server encountered an unexpected condition that prevented it from responding to requests.

Solution: the occurrence of this error is fatal, indicating that the problem is very serious and needs to be checked from the location of the problem, which needs to be solved with the cooperation of the developers of this program, and the cause is determined according to the actual situation. Testers cannot solve the problem alone and should solve it as soon as possible in order to facilitate later testing.

43.LoadRunner request cannot be found: in the process of recording Web protocol script playback script, the request cannot be found, which causes the script to stop running.

Error phenomenon: Action.c (41): Error-27979: Requested form. Not found [MsgId: MERR-27979]

Action.c (41): web_submit_form. Highest severity level was "ERROR", 0 body bytes, 0 header bytes [MsgId: MMSG-27178] "

The associated URL for this component is not seen in tree view at this time.

Error analysis: the selected recording script mode is incorrect. In general, browser-based Web applications use "HTML-based script" mode to record scripts. While there is no browser-based Web application, the Web application contains Java Applet that interacts with the server, the browser-based application contains the JavaScript/VBScript code to communicate with the server, and the browser-based application uses HTTPS security protocol. In this case, the "URL-based script" mode is used for recording.

Solution: open the recording options configuration dialog box to set, in the "Internet Protocol" option of "Recording Options", select "Recording Level" as "HTML-based script" in "Recording", click "HTML Advanced", and select "Script. Type" to "A script. Containing explicit". Then choose to use URL-based script mode to record the script.

44.LoadRunner does not perform the check method: the check method Web_find is added to the recorded Web protocol script, but it is not executed during script playback.

Error: insert the function Web_find in the script and set the checkpoint of the text and image in the script, but the checkpoint is not checked during playback, that is, Web_find is invalid.

Error analysis: because the check function consumes some resources, LoadRunner turns off the inspection of text and images by default, so you need to turn on the check function after setting the checkpoint.

Solution: open the runtime environment settings dialog box for settings, and check the "Enable Image and text check" option under "Check" in "Perference" in the "Internet Protocol" option of "Run-time Settings".

45.LoadRunner playback Web Services protocol script error: version 8.0 of LoadRunner works normally when recording a Web Services protocol script, but an error occurs during playback and prompts you to stop the script.

Error phenomenon: there is no error message when using LoadRunner version 8.0 to record the Web Services protocol script, and the following error message "Error:server returned an incorrectly formatted SOAP response" will appear when playing back the script.

Error analysis: the reason for this error is that LoadRunner8.0 has a defect when recording the script of Web Services protocol: if the operating system of the server is Chinese, VuGen will automatically change the header of the WSDL file to the header of the WSDL file, so there is this error message.

Solution: download two patches, "LR80WebServicesFPI_setup.exe" and "lrunner_web_ services_patch_1.exe", and install them.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report