在一段时间后得到结果的远程jmeter-server错误

我有一个问题,我从我的电脑使用Jmeter驱动安装在RHEL5.8上的Jmeter服务器

我的Java版本是:

[jmeter@sem-osb logs]$ cat /etc/redhat-release Red Hat Enterprise Linux Server release 5.8 (Tikanga) [jmeter@sem-osb logs]$ java -version java version "1.7.0_51" Java(TM) SE Runtime Environment (build 1.7.0_51-b13) Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode) 

我的电脑运行ArchLinux。 在两个我使用相同版本的Jmeter,即:jmeter.JMeter:版本2.11 r1554548

所以我尝试运行一个简单的testing,对soap webservice发出3个请求,并尝试模拟永久运行这些请求的2个客户端(我想加载服务器)。

一段时间后,我收到了jmeter-server.log,下面的错误:

 2014/04/23 14:57:39 INFO - jmeter.util.JMeterUtils: Setting Locale to fr_FR 2014/04/23 14:57:39 INFO - jmeter.util.JMeterUtils: Could not find resources for 'fr_FR', using 'fr' 2014/04/23 14:57:39 INFO - jmeter.JMeter: Loading user properties from: /appli/jmeter/jmeter/bin/user.properties 2014/04/23 14:57:39 INFO - jmeter.JMeter: Loading system properties from: /appli/jmeter/jmeter/bin/system.properties 2014/04/23 14:57:39 INFO - jmeter.JMeter: Setting System property: java.rmi.server.hostname=172.30.96.210 2014/04/23 14:57:39 INFO - jmeter.JMeter: Setting System property: server_port=1099 2014/04/23 14:57:39 INFO - jmeter.JMeter: Copyright (c) 1998-2014 The Apache Software Foundation 2014/04/23 14:57:39 INFO - jmeter.JMeter: Version 2.11 r1554548 2014/04/23 14:57:39 INFO - jmeter.JMeter: java.version=1.7.0_51 2014/04/23 14:57:39 INFO - jmeter.JMeter: java.vm.name=Java HotSpot(TM) 64-Bit Server VM 2014/04/23 14:57:39 INFO - jmeter.JMeter: os.name=Linux 2014/04/23 14:57:39 INFO - jmeter.JMeter: os.arch=amd64 2014/04/23 14:57:39 INFO - jmeter.JMeter: os.version=2.6.18-308.11.1.el5 2014/04/23 14:57:39 INFO - jmeter.JMeter: file.encoding=UTF-8 2014/04/23 14:57:39 INFO - jmeter.JMeter: Default Locale=français (France) 2014/04/23 14:57:39 INFO - jmeter.JMeter: JMeter Locale=français (France) 2014/04/23 14:57:39 INFO - jmeter.JMeter: JMeterHome=/appli/jmeter/jmeter 2014/04/23 14:57:39 INFO - jmeter.JMeter: user.dir =/appli/jmeter/jmeter 2014/04/23 14:57:39 INFO - jmeter.JMeter: PWD =/appli/jmeter/jmeter 2014/04/23 14:57:39 INFO - jmeter.JMeter: IP: 172.30.96.210 Name: **** FullName: **** 2014/04/23 14:57:40 INFO - jmeter.engine.RemoteJMeterEngineImpl: Starting backing engine on 1099 2014/04/23 14:57:40 INFO - jmeter.engine.RemoteJMeterEngineImpl: Local IP address=172.30.96.210 2014/04/23 14:57:40 INFO - jmeter.engine.RemoteJMeterEngineImpl: IP address is a site-local address; this may cause problems with remote access. Can be overridden by defining the system property 'java.rmi.server.hostname' - see jmeter-server script file 2014/04/23 14:57:40 INFO - jmeter.engine.RemoteJMeterEngineImpl: Creating RMI registry (server.rmi.create=true) 2014/04/23 14:57:40 INFO - jmeter.engine.RemoteJMeterEngineImpl: Bound to registry on port 1099 2014/04/23 14:58:00 WARN - jmeter.engine.RemoteJMeterEngineImpl: Backing engine is null, ignoring reset 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleEvent: List of sample_variables: [] 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Cannot find .className property for htmlParser, using default 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Parser for text/html is 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Parser for application/xhtml+xml is 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Parser for application/xml is 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Parser for text/xml is 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPSamplerBase: Parser for text/vnd.wap.wml is org.apache.jmeter.protocol.http.parser.RegexpHTMLParser 2014/04/23 14:58:00 INFO - jmeter.samplers.BatchSampleSender: Using batching for this run. Thresholds: num=100, time=60000 2014/04/23 14:58:00 INFO - jmeter.samplers.DataStrippingSampleSender: Using DataStrippingSampleSender for this run 2014/04/23 14:58:00 INFO - jmeter.engine.RemoteJMeterEngineImpl: Creating JMeter engine on host 172.30.96.210 base '.' 2014/04/23 14:58:00 INFO - jmeter.engine.RemoteJMeterEngineImpl: Remote client host: 172.30.102.135 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Listeners will be started after enabling running version 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: To revert to the earlier behaviour, define jmeterengine.startlistenerslater=false 2014/04/23 14:58:00 INFO - jmeter.services.FileServer: Default base='/appli/jmeter/jmeter' 2014/04/23 14:58:00 INFO - jmeter.services.FileServer: Set new base='.' 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Applying properties {} 2014/04/23 14:58:00 INFO - jmeter.engine.RemoteJMeterEngineImpl: Running test 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Running the test! 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleEvent: List of sample_variables: [] 2014/04/23 14:58:00 INFO - jmeter.engine.util.CompoundVariable: Note: Function class names must contain the string: '.functions.' 2014/04/23 14:58:00 INFO - jmeter.engine.util.CompoundVariable: Note: Function class names must not contain the string: '.gui.' 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Starting ThreadGroup: 1 : Groupe d'unités 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Starting 2 threads for group Groupe d'unités. 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: Test will stop on error 2014/04/23 14:58:00 INFO - jmeter.threads.ThreadGroup: Starting thread group number 1 threads 2 ramp-up 60 perThread 30000.0 delayedStart=false 2014/04/23 14:58:00 INFO - jmeter.threads.JMeterThread: jmeterthread.startearlier=true (see jmeter.properties) 2014/04/23 14:58:00 INFO - jmeter.threads.JMeterThread: Running PostProcessors in forward order 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPHCAbstractImpl: Local host = **** 2014/04/23 14:58:00 INFO - jmeter.protocol.http.sampler.HTTPHC3Impl: HTTP request retry count = 0 2014/04/23 14:58:00 INFO - jmeter.threads.ThreadGroup: Started thread group number 1 2014/04/23 14:58:00 INFO - jmeter.engine.StandardJMeterEngine: All thread groups have been started 2014/04/23 14:58:00 INFO - jmeter.threads.JMeterThread: Thread started: Groupe d'unités 1-1 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleResult: Note: Sample TimeStamps are START times 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleResult: sampleresult.default.encoding is set to ISO-8859-1 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleResult: sampleresult.useNanoTime=true 2014/04/23 14:58:00 INFO - jmeter.samplers.SampleResult: sampleresult.nanoThreadSleep=5000 2014/04/23 14:58:30 INFO - jmeter.threads.JMeterThread: Thread started: Groupe d'unités 1-2 2014/04/23 14:59:21 INFO - jmeter.threads.JMeterThread: Stop Test detected by thread: Groupe d'unités 1-2 2014/04/23 14:59:21 INFO - jmeter.threads.JMeterThread: Thread finished: Groupe d'unités 1-2 2014/04/23 14:59:21 INFO - jmeter.threads.JMeterThread: Stopping: Groupe d'unités 1-2 2014/04/23 14:59:21 INFO - jmeter.threads.JMeterThread: Stopping: Groupe d'unités 1-1 2014/04/23 14:59:21 ERROR - jmeter.threads.RemoteThreadsListenerWrapper: java.rmi.ConnectIOException: Exception creating connection to: 172.30.102.135; nested exception is: java.net.NoRouteToHostException: Ne peut attribuer l'adresse demandée at sun.rmi.transport.tcp.TCPEndpoint.newSocket(Unknown Source) at sun.rmi.transport.tcp.TCPChannel.createConnection(Unknown Source) at sun.rmi.transport.tcp.TCPChannel.newConnection(Unknown Source) at sun.rmi.server.UnicastRef.invoke(Unknown Source) at org.apache.jmeter.threads.RemoteThreadsListenerImpl_Stub.threadFinished(Unknown Source) at org.apache.jmeter.threads.RemoteThreadsListenerWrapper.threadFinished(RemoteThreadsListenerWrapper.java:61) at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:599) at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:961) at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:946) at org.apache.jmeter.threads.JMeterThread.threadFinished(JMeterThread.java:571) at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:310) at java.lang.Thread.run(Unknown Source) Caused by: java.net.NoRouteToHostException: Ne peut attribuer l'adresse demandée at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source) at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source) at java.net.AbstractPlainSocketImpl.connect(Unknown Source) at java.net.SocksSocketImpl.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at java.net.Socket.connect(Unknown Source) at java.net.Socket.<init>(Unknown Source) at java.net.Socket.<init>(Unknown Source) at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(Unknown Source) at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(Unknown Source) ... 12 more 2014/04/23 14:59:21 INFO - jmeter.threads.JMeterThread: Thread finished: Groupe d'unités 1-1 2014/04/23 14:59:21 INFO - jmeter.engine.StandardJMeterEngine: Notifying test listeners of end of test 2014/04/23 14:59:21 INFO - jmeter.samplers.DataStrippingSampleSender: Test Ended on 172.30.96.210 2014/04/23 14:59:21 INFO - jmeter.samplers.BatchSampleSender: Test Ended on 172.30.96.210 2014/04/23 14:59:21 INFO - jmeter.engine.StandardJMeterEngine: Test has ended on host 172.30.96.210 

在错误中提到的ip,172.30.102.135是我开始testing的ip,意思是我的电脑。 所以看起来在一段时间之后,jmeter-server不能再连接到我了。 问题是,在此之前我收到了很多结果,所以networkingconfiguration没有任何问题。 testing正在停止,因为我要求它在发生任何错误后停止,但是如果我不检查此选项,它会继续,将更多的错误添加到日志文件中。 我想也许是在/etc/security/limits.conf里面可能会改变一些东西,但我并不确定。 我真的很感激任何想法。

如果你需要更多的细节,请问。

我已经从这个网站获得帮助: http : //howtojboss.com/2012/07/31/concurrent-high-throughput-performance-testing-with-jmeter/

解决的办法是使用这个参数,似乎当你打开太多的连接时,用于旧的端口在TIME_WAIT状态下停留时间太长,所以这有助于:

 echo 1 > /proc/sys/net/ipv4/tcp_tw_recycle