JMeter:连接被拒绝的主机:127.0.1.1 [英] JMeter: Connection refused to host: 127.0.1.1
问题描述
我的本地主机使用./jmeter
My localhost runs a Jmeter GUI with ./jmeter
我正在尝试在远程服务器上运行JMeter.我正在新的VM实例上运行JMeter-server,并在桌面上运行GUI客户端.
远程服务器ip是148.6.60.8
I'm trying to run JMeter on a remote server. I'm running JMeter-server on a new VM instance, and the GUI client from my desktop.
the remote server ip is 148.6.60.8
我已经编辑了jmeter-server文件RMI_HOST_DEF=-Djava.rmi.server.hostname=148.6.60.8
I've edited jmeter-server file RMI_HOST_DEF=-Djava.rmi.server.hostname=148.6.60.8
从客户端连接时,我得到
When connecting from client I get
ERROR - jmeter.samplers.RemoteTestListenerWrapper: java.rmi.ConnectException: Connection refused to host: 127.0.1.1; nested exception is:
java.net.ConnectException: Connection refused
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619)
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216)
at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:129)
at java.rmi.server.RemoteObjectInvocationHandler.invokeRemoteMethod(RemoteObjectInvocationHandler.java:227)
at java.rmi.server.RemoteObjectInvocationHandler.invoke(RemoteObjectInvocationHandler.java:179)
at com.sun.proxy.$Proxy1.testEnded(Unknown Source)
at org.apache.jmeter.samplers.RemoteTestListenerWrapper.testEnded(RemoteTestListenerWrapper.java:79)
at org.apache.jmeter.engine.StandardJMeterEngine.notifyTestListenersOfEnd(StandardJMeterEngine.java:228)
at org.apache.jmeter.engine.StandardJMeterEngine.run(StandardJMeterEngine.java:448)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at java.net.Socket.connect(Socket.java:528)
at java.net.Socket.<init>(Socket.java:425)
at java.net.Socket.<init>(Socket.java:208)
at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40)
at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:147)
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613)
推荐答案
在user.properties中添加到客户端jmeter:
Add to your client jmeter in user.properties:
host = 148.6.60.8
host=148.6.60.8
否则,JMeter不能猜测它需要连接到该IP上的远程服务器.
Otherwise JMeter can't guess that it needs to connect to the remote server on this IP.
这篇关于JMeter:连接被拒绝的主机:127.0.1.1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!