loadrunner错误分析及解决办法

上一篇 / 下一篇  2010-03-23 14:14:39

对LR回放中highest severity level was"ERROR"的一个解决方法

在LR中录制脚本时有如下问题:
在录制时一切正常,而回放时提示类似如下错误:
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]"
 这时在tree view中看不到此组件的相关URL。
 
处理方法如下:
1, 打开recording options,在internet protocol下的recording中选择recording level为HTML-based script,点击HTML Advanced,选择script. type为A script. containing explicit.即可。
2, 选择使用URL_based script录制。
另外,附上帮助中的这个错误代码的说明:
Message Code 27979
Requested form. not found

The form. was not found in the page received from the server. Possible reasons: (i) The current or a previous HTML page was changed after the script. was recorded. (ii) A previous request navigated to a wrong page or failed. (iii) One or more web_submit_form. arguments are missing or incorrect (especially for manually coded, parameterized, or correlated functions). (iv) The server returned an unexpected page (e.g., under excessive load).

Troubleshooting
If the current or previous HTML page was changed, look for the correct properties of the form. used in the text (e.g., action), and change it in the script.
If your snapshots and extended log are disabled, enable them and run the script. again.
(i) To enable Snapshots: Select Tools > General Options > Correlation, and check the Save correlation information during replay box.
(ii) To enable Extended Log: Select Run-time Settings > General: Log, and check Enable logging, Always send messages, Extended log, Data returned by server, Advanced trace.
Compare the record and replay snapshots for each step in the script. from the beginning, and locate the first difference. If you identify a difference in the snapshots, locate the corresponding HTTP request in both the recording log and the extended log. Compare the requests and, if they are different, have the replay issue exactly the same request. This can be done, for example, by adding web_add_header (for adding missing headers or adjusting existing ones), web_remove_auto_header (for removing extra headers), and web_add_cookie (for missing cookies).
If some correlation is missing, (e.g., the recording and replay runs have different session IDs), use the correlation tool to locate and handle such cases.

 

Error -26612: HTTP Status-Code=500 (Internal Server Error)

最近在测试一系统的时候,录制脚本没有错误,回放的时候总是出现如下错误:
Action.c(6): Error -26612: HTTP Status-Code=500 (Internal Server Error) for "http://192.168.0.110:7001/logonConsole.do;jsessionid={JSESSIONID2}"

造成HTTP-500错误,有朋友告诉我如下几个可能:

1、运行的用户数过多,对服务器造成的压力过大,服务器无法响应,则报HTTP500错误。减小用户数或者场景持续时间,问题得到解决。

2、该做关联的地方没有去做关联,则报HTTP500错误。进行手工或者自动关联,问题得到解决。

3、录制时请求的页面、图片等,在回放的时候服务器找不到,则报HTTP500错误,若该页面无关紧要,则可以在脚本中注释掉,问题将会得到解决。例如:有验证码的情况下,尽管测试时已经屏蔽了,但是录制的时候提交了请求,但回放的时候不存在响应。

4、参数化时的取值有问题,则报HTTP500错误。可将参数化列表中的数值,拿到实际应用系统中进行测试,可排除问题。

5、更换了应用服务器(中间件的更换,如tomcat、websphere、jboss等),还是利用原先录制的脚本去运行,则很可能报HTTP500错误。因为各种应用服务器处理的机制不一样,所录制的脚本也不一样,解决办法只有重新录制脚本。

6、Windows xp2 与ISS组件不兼容,则有可能导致HTTP500错误。对ISS组件进行调整后问题解决。

7、系统开发程序写的有问题,则报HTTP500错误。例如有些指针问题没有处理好的,有空指针情况的存在。修改程序后问题解决。

查找后台日志发现报了很多0ra-01000错误,这是oracle达到最大游标参数值,google了下,最大原因可能是JDBC连接没关闭。最后查找weblogic连接池出了问题,很多连接没关闭。


TAG:

 

评分:0

我来说两句

Open Toolbar