jmeter在linux上启动报错:连接拒绝

最近在linux上使用jmeter进行压测时,遇到了下面问题:

使用jmeter-server启动jmeter server报错,提示中的endpoint并不是该server的ip:

server的ip是内网的192.168.60.223,但endpoint却是202.106.199.37,貌似是联通的一个外网ip。

[root@host_60_223 bin]# ./jmeter-server

Created remote object: UnicastServerRef [liveRef: [endpoint:[202.106.199.37:48777](local),objID:[114b877d:1535f0bf800:-7fff, -8953048443915791496]]]

Server failed to start: java.rmi.RemoteException: Cannot start. See server log file.; nested exception is: 

java.rmi.ConnectException: Connection refused to host: 202.106.199.37; nested exception is: 

java.net.ConnectException: 连接超时

An error occurred: Cannot start. See server log file.; nested exception is: 

java.rmi.ConnectException: Connection refused to host: 202.106.199.37; nested exception is: 

java.net.ConnectException: 连接超时

通过网上各种查询,有人说是hostname在hosts文件中没有配置,这个一般都需要配置吗?

虽然疑问但没有找到别的解决办法,只能试试看:

[root@host_60_223 bin]# hostname

host_60_223

修改/etc/hosts文件加入下面的ip hostname

vi /etc/hosts

192.168.60.223 host_60_223


果然跟这个有关,至于为什么现在还不清楚。

[root@host_60_223 bin]# ./jmeter-server

Created remote object: UnicastServerRef [liveRef: [endpoint:[192.168.60.223:36259](local),objID:[3d1e428a:1535f20e6c7:-7fff, -6723038591539730142]]]


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值