Connection refused 对端服务没启动
node2:/root/test#cat connect1.py
# -*- coding: utf-8 -*-
import socket
import time
s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
s.settimeout(3000)
s.connect(("192.168.137.101",8080))
s.send('aaaaaaaaaaaaaaa')
print s.recv(100)
node2:/root/test#python connect1.py
Traceback (most recent call last):
File "connect1.py", line 6, in <module>
s.connect(("192.168.137.101",8080))
File "/usr/local/python27/lib/python2.7/socket.py", line 227, in meth
return getattr(self._sock,name)(*args)
socket.error: [Errno 111] Connection refused
Connection refused 对端服务没启动
最新推荐文章于 2023-03-07 11:32:51 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)