zoukankan      html  css  js  c++  java
  • jmeter分布式测试的坑(转)

    本文转自:https://www.cnblogs.com/lsjdddddd/p/5806077.html

    有关jmeter分布式测试的环境配置,大概就是那样,但是每次想要进行jmeter分布式测试的时候,总是会有各种奇怪的问题,下面整理了一些可能遇到的坑。

    问题:如果你的服务器名字和报错的时候显示的服务器名不一致(refuse to host:10.10.34.21,而服务器名明明是172.16.129.43)

    只要错误中出现:Error in rconfigure() method java.rmi.ConnectException:Connection refused to host:10.10.34.21;nested exception is:java.net.ConnectException:connection timed out:connect

    那就就是服务器之间没有连通。

     

    方案:这是服务器双网卡造成的问题

    在linux上 修改jmeter-server

    RMI_HOST_DEF=-Djava.rmi.server.hostname=slave机器名

    在windows上 修改jmeter.bat

    新增set rmi_host=-Djava.rmi.server.hostname=本机ip

    修改set ARGS=%DUMP% %HEAP% %NEW% %SURVIVOR% %TENURING% %PERM% %DDRAW% %rmi_host%

    问题:如果机器可以开始测试,但是测试速度非常慢,测试结果也是非常大的值。

    方案:检查slave服务器和被测试服务器之间是否可以ping通

    问题:controller机器上收不到slave机器连接过来的信息。

    方案:检查slave服务器的hostname和/etc/hosts中服务器对应的名字是否相同

    问题:slave服务器上可以starting test,但是在jmeter界面上依旧报如下图错误。

    Connection refused to host:172.16.129.43;nested exception is:java.net.ConnectException:Connection timed out:connect.

    方案:检查slave服务器的防火墙是否打开,需要关闭 

    1) 重启后生效

    开启: chkconfig iptables on

    关闭: chkconfig iptables off

    2) 即时生效,重启后失效

    开启: service iptables start

    关闭: service iptables stop

  • 相关阅读:
    ThinkPHP运算符 与 SQL运算符 对比表
    [Java 8] (6) Lambda与资源管理
    Codeforces Round #275 (Div. 2) C
    HOJ 2245 浮游三角胞(数学啊 )
    [UVALive 6663 Count the Regions] (dfs + 离散化)
    浅解ARC中的 __bridge、__bridge_retained和__bridge_transfer
    SpringMVC: web.xml中声明DispatcherServlet时一定要加入load-on-startup标签
    Unity3d 4.3.4f1执行项目
    更新Windows ActiveX,Ios
    C++11: final与override
  • 原文地址:https://www.cnblogs.com/wxinyu/p/10589013.html
Copyright © 2011-2022 走看看