jhwhale 发表于 2009-6-4 14:50:39

测试rtsp时100%出现Error : 9017,Timeout expired while trying to connect

大家好 我是个LR初学者,在测rtsp的时候遇到一些问题,也上网查了很多资料,但是好像都没有用。想请大家帮帮忙,帮我看看到底是哪里出了错。还希望大家说的详细点,小妹在这里先谢过了~

我选的是winsocket,然后录制用Windows Media player 打开一段用Windows Media Service发布的rtsp的流媒体。
不管运行多少个vu都会100% fail,出现同样数量的error:Action.c(12): Error : Timeout expired while trying to connect. Error code : 9017

我在Controller里选择的是load all vu simultaneously、run until completion,并选中initialized all vu before run
之后直接start scenario 结果就会全部fail。

请大家帮帮忙吧,不胜感激!

下面是我录制的脚本
/*********************************************************************
* Created by Mercury Interactive Windows Sockets Recorder
*
* Created on: Thu Jun 04 13:55:26
*********************************************************************/

#include "lrs.h"


Action()
{
    lrs_create_socket("socket0", "TCP", "LocalHost=0", "RemoteHost=xue5vifulmlrgpm.domain:554",LrsLastArg);

    lrs_send("socket0", "buf0", LrsLastArg);

    lrs_receive("socket0", "buf1", LrsLastArg);

    lrs_send("socket0", "buf2", LrsLastArg);

    lrs_receive("socket0", "buf3", LrsLastArg);

    lrs_create_socket("socket1", "UDP", "LocalHost=1667", "RemoteHost=xue5vifulmlrgpm.domain:5005",LrsLastArg);

    lrs_create_socket("socket2", "UDP", "LocalHost=0",LrsLastArg);

    lrs_send("socket0", "buf4", LrsLastArg);

    lrs_receive("socket2", "buf5", LrsLastArg);

    lrs_create_socket("socket3", "TCP", "LocalHost=0", "RemoteHost=207.46.250.101:80",LrsLastArg);

    lrs_send("socket3", "buf6", LrsLastArg);

    lrs_send("socket0", "buf7", LrsLastArg);

    lrs_receive("socket0", "buf8", LrsLastArg);

    lrs_send("socket0", "buf9", LrsLastArg);

    lrs_receive("socket0", "buf10", LrsLastArg);

    lrs_send("socket0", "buf11", LrsLastArg);

    lrs_receive("socket0", "buf12", LrsLastArg);

    lrs_send("socket0", "buf13", LrsLastArg);

    lrs_receive("socket0", "buf14", LrsLastArg);

    lrs_receive("socket3", "buf15", LrsLastArg);

    lrs_close_socket("socket3");

    lrs_receive("socket0", "buf16", LrsLastArg);

    lrs_create_socket("socket4", "TCP", "LocalHost=0", "RemoteHost=207.46.250.101:80",LrsLastArg);

    lrs_receive("socket0", "buf17", LrsLastArg);

    lrs_create_socket("socket5", "TCP", "LocalHost=0", "RemoteHost=210.51.19.247:80",LrsLastArg);

    lrs_create_socket("socket6", "TCP", "LocalHost=0", "RemoteHost=bt-199-035.bta.net.cn:80",LrsLastArg);

    lrs_create_socket("socket7", "TCP", "LocalHost=0", "RemoteHost=60.28.162.239:80",LrsLastArg);

    lrs_receive("socket0", "buf18", LrsLastArg);

    lrs_send("socket5", "buf19", LrsLastArg);

    lrs_receive("socket0", "buf20", LrsLastArg);

    lrs_send("socket4", "buf21", LrsLastArg);

    lrs_send("socket6", "buf22", LrsLastArg);

    lrs_receive("socket0", "buf23", LrsLastArg);

    lrs_receive("socket5", "buf24", LrsLastArg);

    lrs_receive("socket0", "buf25", LrsLastArg);

    lrs_receive("socket6", "buf26", LrsLastArg);

    lrs_close_socket("socket6");

    lrs_receive("socket4", "buf27", LrsLastArg);

    lrs_close_socket("socket4");

    lrs_receive("socket0", "buf28", LrsLastArg);

    lrs_send("socket7", "buf29", LrsLastArg);

    lrs_receive("socket0", "buf30", LrsLastArg);

    lrs_receive("socket7", "buf31", LrsLastArg);

    lrs_receive("socket0", "buf32", LrsLastArg);

    return 0;
}

jhwhale 发表于 2009-6-4 17:21:13

急 啊

之后我把socket0 和socket1 改成下面这样了,但是9017那个错误就没有了,但是会出现error 10048:
Action.c(22): Error : socket1 - Address already in use. Error code : 10048
而且每次都只有1个vu pass 其他都fail,我觉得应该吧ip关联一下,但是winsocket里好像没有关联函数,该怎么办啊?

    lrs_create_socket("socket0", "TCP", "LocalHost=0", "RemoteHost=207.46.250.110:80",LrsLastArg);

    lrs_create_socket("socket1", "UDP", "LocalHost=1667", "RemoteHost=217.46.250.110:80",LrsLastArg);

jhwhale 发表于 2009-6-4 18:43:42

不要沉啊

感觉是每个vu都要占用很多不同的ip,用户之间又不能重复,这该怎么整啊

allen198341 发表于 2009-6-4 21:38:32

关注中,winsocket没试过,我觉得是端口的问题,待高手的出现

jhwhale 发表于 2009-6-5 15:03:23

难道没有人用loadrunner测过rtsp么?

难道没有人用loadrunner测过rtsp么?

kuangquanshui 发表于 2009-6-5 16:52:12

这个不明白 帮你顶了      学习中以后这方面还请你多帮忙

jhwhale 发表于 2009-6-8 08:49:59

谢谢楼上的

咱们论坛有没有QQ群啊 希望找个高手问问

C组十三 发表于 2010-2-1 15:24:57

回复 1# 的帖子

这个问题跟端口有关,把"LocalHost=0"去掉就好了。

端口若被占用,未及时释放,别人再通过此端口发送数据,就会出错。

kuangquanshui 发表于 2011-3-14 11:46:39

我也遇见这个问题了   不论执行多少个用户总有三分之二的用户失败   愁

zhengaiqi 发表于 2013-5-24 12:34:08

我在回放的时候就碰到了。。

小乖乖 发表于 2014-4-14 17:54:46

LR 场景运行时,不管多少用户,总是会掉,这个问题有遇到解决好了的吗?麻烦请赐教哈
页: [1]
查看完整版本: 测试rtsp时100%出现Error : 9017,Timeout expired while trying to connect