Hello.
I have been tearing my hair out about this issue! The issue I am having is MQTT is not working. Specifically I get a warning in the Home Assistant web interface saying.
The following components and platforms could not be set up:
mqtt
light.mqtt
switch.mqtt
Please check your config
I know my config is correct as it was working before. This issue arose when I installed open z wave and a Z- Stick but before that it was working fine. My home assistant log says the following.
2017-06-15 21:21:38 ERROR (MainThread) [homeassistant.setup] Error during setup of component mqtt
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/setup.py", line 187, in _async_setup_component
result = yield from component.async_setup(hass, processed_config)
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/mqtt/__init__.py", line 380, in async_setup
success = yield from hass.data[DATA_MQTT].async_connect()
File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/mqtt/__init__.py", line 490, in async_connect
self._mqttc.connect, self.broker, self.port, self.keepalive)
File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
value = future.result()
File "/usr/lib/python3.4/asyncio/futures.py", line 277, in result
raise self._exception
File "/usr/lib/python3.4/concurrent/futures/thread.py", line 54, in run
result = self.fn(*self.args, **self.kwargs)
File "/home/homeassistant/.homeassistant/deps/paho/mqtt/client.py", line 700, in connect
return self.reconnect()
File "/home/homeassistant/.homeassistant/deps/paho/mqtt/client.py", line 822, in reconnect
sock = socket.create_connection((self._host, self._port), source_address=(self._bind_address, 0))
File "/usr/lib/python3.4/socket.py", line 509, in create_connection
raise err
File "/usr/lib/python3.4/socket.py", line 500, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of switch.mqtt. Setup failed for dependencies: mqtt
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform switch.mqtt: Could not setup all dependencies.
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of light.mqtt. Setup failed for dependencies: mqtt
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform light.mqtt: Could not setup all dependencies.
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of light.mqtt. Setup failed for dependencies: mqtt
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform light.mqtt: Could not setup all dependencies.
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of light.mqtt. Setup failed for dependencies: mqtt
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform light.mqtt: Could not setup all dependencies.
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of light.mqtt. Setup failed for dependencies: mqtt
2017-06-15 21:21:54 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform light.mqtt: Could not setup all dependencies.
If anyone can help me with this I would greatly appreciate it
Riley.