After upgrading to 0.81.2 all my Tasmota flashed Sonoff disappeared

Not sure what it is, I can connect to my mosquitto server (using windoiws programs) just fine

in the log I see this

2018-10-31 07:56:05 ERROR (MainThread) [homeassistant.components.mqtt] Failed to connect due to exception: [Errno -3] Try again

2018-10-31 07:56:31 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 354, in _async_add_entity
    await entity.async_added_to_hass()
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/sensor/mqtt.py", line 177, in async_added_to_hass
    message_received, self._qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 306, in async_subscribe
    topic, msg_callback, qos, encoding)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 688, in async_subscribe
    await self._async_perform_subscription(topic, qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 723, in _async_perform_subscription
    _raise_on_error(result)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 808, in _raise_on_error
    'Error talking to MQTT: {}'.format(mqtt.error_string(result_code)))
homeassistant.exceptions.HomeAssistantError: Error talking to MQTT: The client is not currently connected.
2018-10-31 07:56:31 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 354, in _async_add_entity
    await entity.async_added_to_hass()
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/sensor/mqtt.py", line 177, in async_added_to_hass
    message_received, self._qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 306, in async_subscribe
    topic, msg_callback, qos, encoding)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 688, in async_subscribe
    await self._async_perform_subscription(topic, qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 723, in _async_perform_subscription
    _raise_on_error(result)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 808, in _raise_on_error
    'Error talking to MQTT: {}'.format(mqtt.error_string(result_code)))

The Sonoff works perfectly (if I type 192.168.1.xxx I get the webserver of Tasmota)

HA is not connecting to the broker. What version did you upgrade from?

from 0.80.3 to 0.81.x

HASSIO

this is my config in mosquitto HASSIO addon. In HASSIO addon log I see the devices are connected to the mosquitto

{
  "plain": true,
  "plain_websockets": true,
  "ssl": false,
  "ssl_websockets": false,
  "anonymous": true,
  "logins": [
    {
      "username": "",
      "password": ""
    }
  ],
  "customize": {
    "active": true,
    "folder": "mosquitto"
  },
  "certfile": "fullchain.pem",
  "keyfile": "privkey.pem"
}

this the log (just restarted the addon)

1540979028: mosquitto version 1.4.15 (build date 2018-03-04 15:14:46+0000) starting
1540979028: Config loaded from /etc/mosquitto.conf.
1540979028: Opening ipv4 listen socket on port 1883.
1540979028: Opening ipv6 listen socket on port 1883.
1540979028: Opening websockets listen socket on port 1884.
1540979028: Warning: Mosquitto should not be run as root/administrator.
1540979028: New connection from 192.168.1.173 on port 1883.
1540979028: New client connected from 192.168.1.173 as guest-ac (c1, k15).
1540979028: New connection from 192.168.1.176 on port 1883.
1540979028: New client connected from 192.168.1.176 as oven (c1, k15).
1540979029: New connection from 192.168.1.174 on port 1883.
1540979029: New client connected from 192.168.1.174 as dining_ac (c1, k15).
1540979030: New connection from 192.168.1.163 on port 1883.
1540979030: New client connected from 192.168.1.163 as carrabile14b (c1, k15).
1540979037: New connection from 192.168.1.238 on port 1883.
1540979037: New client connected from 192.168.1.238 as mqtt_openhab (c1, k60).
1540979038: New connection from 192.168.1.175 on port 1883.
1540979038: New connection from 192.168.1.177 on port 1883.
1540979038: New client connected from 192.168.1.177 as water_heater (c1, k15).
1540979038: New connection from 192.168.1.179 on port 1883.
1540979038: New client connected from 192.168.1.179 as guest_room_tv_plug (c1, k15).

I enabled logger, and it does subscribe …??

2018-10-31 11:44:59 DEBUG (MainThread) [homeassistant.components.mqtt] Subscribing to carrabile14b

2018-10-31 11:44:59 DEBUG (MainThread) [homeassistant.components.mqtt] Subscribing to tele/oven/LWT

2018-10-31 11:44:59 DEBUG (MainThread) [homeassistant.components.mqtt] Subscribing to tele/water_heater/LWT

2018-10-31 11:44:59 DEBUG (MainThread) [homeassistant.components.mqtt] Subscribing to tele/guest_room_ac/LWT

2018-10-31 11:44:59 DEBUG (MainThread) [homeassistant.components.mqtt] Subscribing to tele/dining_room_ac/LWT


2018-10-31 11:44:59 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 354, in _async_add_entity
    await entity.async_added_to_hass()
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/sensor/mqtt.py", line 177, in async_added_to_hass
    message_received, self._qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 306, in async_subscribe
    topic, msg_callback, qos, encoding)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 688, in async_subscribe
    await self._async_perform_subscription(topic, qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 723, in _async_perform_subscription
    _raise_on_error(result)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 808, in _raise_on_error
    'Error talking to MQTT: {}'.format(mqtt.error_string(result_code)))
homeassistant.exceptions.HomeAssistantError: Error talking to MQTT: The client is not currently connected.
2018-10-31 11:45:00 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity_platform.py", line 354, in _async_add_entity
    await entity.async_added_to_hass()
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/sensor/mqtt.py", line 177, in async_added_to_hass
    message_received, self._qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 306, in async_subscribe
    topic, msg_callback, qos, encoding)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 688, in async_subscribe
    await self._async_perform_subscription(topic, qos)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 723, in _async_perform_subscription
    _raise_on_error(result)
  File "/usr/local/lib/python3.6/site-packages/homeassistant/components/mqtt/__init__.py", line 808, in _raise_on_error
    'Error talking to MQTT: {}'.format(mqtt.error_string(result_code)))
homeassistant.exceptions.HomeAssistantError: Error talking to MQTT: The client is not currently connected.

The solution is to change from

mqtt:
  broker: core-mosquitto

to

mqtt:
  broker: 192.168.1.10  # core-mosquitto

Very strange.

Thanks to this post

Note that my solution was for a mosquitto broker, not for the built-in mqtt, not sure what the OP is using.

I am using mosquito from hassio addon.

Please note I had a DNS issue, most probably the cause of the problem