51Testing软件测试论坛

标题: WEBSERVICE测试ERROR求助 [打印本页]

作者: guodansong    时间: 2012-11-2 16:29
标题: WEBSERVICE测试ERROR求助
本帖最后由 guodansong 于 2012-11-2 16:36 编辑

问题1,脚本单独跑没问题返回值正确,
但是迭代多次是虽然也成功执行,但是我看了CIQCTN2的返回值是1验证码错误?
问题2:在场景中执行100个用户时候跑8小时,一般第三个小时报外部组件异常
问题3:在场景中执行30个用户线程thread跑8小时有个别用户报Abnormal termination, caused by mdrv process termination
疯了
问题4:在场景执行30个用户进程跑5个小时,4G内存的宿主机器,结果弹出很多窗口负载过大宕机了


代码参照:第一个CALL是验证码,第二个CALL是根据验证码查询NEWPARAM的信息

Action()
{
  lr_start_transaction("UUMM1");

        web_service_call( "StepName=queryData_101",
                "SOAPMethod=GCCData|GCCDataPort|queryData",
                "ResponseParam=response",
                "Service=GCCData",
                "ExpectedResponse=SoapResult",
                "Snapshot=t1351746364.inf",
                BEGIN_ARGUMENTS,
                "queryData1=<?xml version=\"1.0\" encoding=\"utf-8\"?><GCCQuery xmlns=\"biz.easipass.com\"><Info><QueryType>UUMM1</QueryType><Authenticator><user>a</user><password>a</password><sign>0123456789</sign></Authenticator></Info><Criteria><Key><name>LOGIN_ID</name><value>320501</value></Key><Key relation=\"and\"><name>LOGIN_PASS</name><value>320501</value></Key></Criteria></GCCQuery>",
                END_ARGUMENTS,
                BEGIN_RESULT,
                "queryDataResult=Param_queryDataResult",
                END_RESULT,
                LAST);

    lr_end_transaction("UUMM1", LR_AUTO);

        lr_save_var( lr_eval_string("{Param_queryDataResult}")+894,
                                        14, 0, "ShortName");

        lr_output_message("ShortName=%s",lr_eval_string("{ShortName}"));


        lr_start_transaction("CIQCTN2");

        web_service_call( "StepName=queryData_102",
                "SOAPMethod=GCCData|GCCDataPort|queryData",
                "ResponseParam=response",
                "Service=GCCData",
                "ExpectedResponse=SoapResult",
                "Snapshot=t1351746419.inf",
                BEGIN_ARGUMENTS,
                "queryData1=<?xml version=\"1.0\" encoding=\"utf-8\"?><GCCQuery xmlns=\"biz.easipass.com\"><Info><QueryType>CIQCTN2</QueryType><Authenticator><user>a</user><password>a</password><sign>0123456789</sign></Authenticator></Info><Criteria><Key><name>USER_ID</name><value>1106</value></Key><Key relation=\"and\"><name>MSG_UID</name><value>{NewParam}</value></Key><Key relation=\"and\"><name>LOGONSTR</name><value>{ShortName}</value></Key></Criteria></GCCQuery>",
                END_ARGUMENTS,
                BEGIN_RESULT,
                "queryDataResult=Param_queryDataResult2",
                END_RESULT,
                LAST);

    lr_end_transaction("CIQCTN2", LR_AUTO);
        lr_output_message("RESULTEND=%s",lr_eval_string("{Param_queryDataResult2}"));
        return 0;
}
作者: guodansong    时间: 2012-11-2 16:34
问题1,脚本单独跑没问题返回值正确,
但是迭代多次是虽然也成功执行,但是我看了CIQCTN2的返回值是1验证码错误?
问题2:在场景中执行100个用户时候跑8小时,一般第三个小时报外部组件异常
问题3:在场景中执行30个用户线程thread跑8小时有个别用户报Abnormal termination, caused by mdrv process termination
疯了
问题4:在场景执行30个用户进程跑5个小时,4G内存的宿主机器,结果弹出很多窗口负载过大宕机了
作者: guodansong    时间: 2012-11-2 16:38
搜索别人的解决方案;问题:运行场景后,提示“Abnormal termination, caused by mdrv process termination”,服务端没有挂,仍可正常访问,且在运行场景时,没有自动重启。找下了,网上的答案如下:

转自:http://loadrunner.wetpaint.com/page/Abnormal+termination,+caused+by+mdrv+process+termination

Hi, Users facing this mdrv process abnormal termination can try one of these options found from one of the LR articles. The Loadrunner vusers are run by a process called 'mdrv.exe'. Whenever this process encounters errors due to various reasons it may terminate. Some of the possible reasons are as follows
1.The Host machine ( Load generator) is running too many Vusers as a result of which it system resources are being maximized. ( i.e. Consistent over 90% CPU and Memory utilization). The mdrv process does not get enough resources to process the request as a result it fails
2.If you have Custom C coding, there is a possibility of allocated memory not being freed or memory violation errors which can lead to 'mdrv process termination'.
3.Replay the script with think time.
4.Turn off extended log when running the script in the controller.
5.Do not use the controller itself as the loadgenerator. i.e. have a remote LoadGenerator.
6.Introduce iteration pacing, if running more than one iteration each vuser.
7.Open the file C:\WinNT\wlrun7.ini in a text editor, modify the entry from: AgentMaxThreadsPerDriver=50 to AgentMaxThreadsPerDriver=20 or 10
8.Run Agent as process instead of service Launch command prompt and navigate to C:\Program Files\Mercury\Loadrunner\Launch_service\bin and run the command magentserive -remove. This will remove the agent. Now run the command magentproc -install This will install the agent as a process.
9.Run vusers as process instead of threads.Please go to Runtime Settings > Miscellaneous > Multithreading > RunVuser as a process
作者: guodansong    时间: 2012-11-2 16:38
但是我还是没有解决崩溃中
作者: guodansong    时间: 2012-11-5 14:18
后来减压,50个用户依然会有个别的资源不足,后来30个用户跑8个小时,资源OK全部通过




欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/) Powered by Discuz! X3.2