eschava / broadlink-mqtt

MQTT client to control BroadLink devices
MIT License
224 stars 61 forks source link

socket.error: [Errno 111] Connection refused #27

Closed multima closed 6 years ago

multima commented 6 years ago

Hi, I get the below error when I lunch mqtt.py.

[2018-05-20 10:54:14,535] DEBUG Connected to RM2 Broadlink device at '192.168.0.56' (MAC xx:xx:xx:xx:xx:xx) Traceback (most recent call last): File "mqtt.py", line 385, in mqttc.connect(cf.get('mqtt_broker', 'localhost'), int(cf.get('mqtt_port', '1883')), 60) File "/home/pi/.local/lib/python2.7/site-packages/paho/mqtt/client.py", line 768, in connect return self.reconnect() File "/home/pi/.local/lib/python2.7/site-packages/paho/mqtt/client.py", line 895, in reconnect sock = socket.create_connection((self._host, self._port), source_address=(self._bind_address, 0)) File "/usr/lib/python2.7/socket.py", line 575, in create_connection raise err socket.error: [Errno 111] Connection refused

eschava commented 6 years ago

Do you have MQTT broker run at the local box?

yz665 commented 6 years ago

I have same issue. Anyone resolved it ?

eschava commented 6 years ago

@yz665 Same question: Do you have MQTT broker run at the local box?

g0tama commented 5 years ago

Hi I have the same issue. And I think I have a broker on local box. Any solution to resolve it? Thanks

yz665 commented 5 years ago

I solved my problem by run "mosquitto -d" command. Good luck