Trying to link my CloudMQTT account in my configuration.yaml
I need OwnTracks to track two different phones for location/automation.
I’ve tried an assortment of configurations, but can someone point out how to fill out the configuration for an mqtt broker with these example settings?
Somebody chime in if I’m doing this wrong but the way I have it working is (based on your example):
Broker: m12.cloudmqtt.com
Port: 24938
Username: homeassistant
Password: the password you created for the homeassistant user
You then have to make separate usernames and passwords for the phones you want to connect and set up the ACL’s the same as the first one. Each phone will be set up with its unique username and password.
That is what I tried, but I keep getting this:
> 16-05-17 21:55:04 homeassistant.components.mqtt: Can’t connect to the broker. Please check your settings and the broker itself.
> Traceback (most recent call last):
> File “/usr/src/app/homeassistant/components/mqtt/init.py”, line 238, in setup
> client_cert, tls_insecure, protocol)
> File “/usr/src/app/homeassistant/components/mqtt/init.py”, line 324, in init
> self._mqttc.connect(broker, port, keepalive)
> File “/usr/local/lib/python3.4/site-packages/paho/mqtt/client.py”, line 612, in connect
> return self.reconnect()
> File “/usr/local/lib/python3.4/site-packages/paho/mqtt/client.py”, line 747, in reconnect
> ciphers=self._tls_ciphers)
> File “/usr/local/lib/python3.4/ssl.py”, line 890, in wrap_socket
> ciphers=ciphers)
> File “/usr/local/lib/python3.4/ssl.py”, line 580, in init
> self.do_handshake()
> File “/usr/local/lib/python3.4/ssl.py”, line 807, in do_handshake
> self._sslobj.do_handshake()
> ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:600)
> 16-05-17 21:55:04 homeassistant.bootstrap: component mqtt failed to initialize
Is anyone else having an issue with cloudMQTT? I try to look at the server log and get an “unknown error”
Nope, I’m using the same server and have no issues. But I didn’t change the port setup and instead used the defaults (17070, 27070 and 37070). In my case I connect on 17070.
I don’t see it - I get unknown error. But if I go to the websocket UI, I see my messages coming though from my device. If it were me, I would start by standardizing everything. Use the default ports in your setup. Match it in your device client as well.
Or were these the ports assigned to you when you first created the instance?
Hi. My cloudmqtt + owntracks configuration seems to be working however I’m getting these errors:
16-07-04 22:33:01 homeassistant.components.device_tracker: Error setting up platform owntracks
Traceback (most recent call last):
File "/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/components/device_tracker/__init__.py", line 133, in setup_platform
if not platform.setup_scanner(hass, p_config, tracker.see):
File "/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/components/device_tracker/owntracks.py", line 180, in setup_scanner
mqtt.subscribe(hass, LOCATION_TOPIC, owntracks_location_update, 1)
File "/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/components/mqtt/__init__.py", line 174, in subscribe
MQTT_CLIENT.subscribe(topic, qos)
File "/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/components/mqtt/__init__.py", line 346, in subscribe
_raise_on_error(result)
File "/srv/hass/hass_venv/lib/python3.4/site-packages/homeassistant/components/mqtt/__init__.py", line 444, in _raise_on_error
raise HomeAssistantError('Error talking to MQTT: {}'.format(result))
homeassistant.exceptions.HomeAssistantError: Error talking to MQTT: 1
I’m seeing the same SSL handshake errors and I’m also on the m12 server. I know the homeassistant setup instructions for cloudmqtt indicate that homeassistant will automatically load the correct cert, I wonder if it just doesn’t have one for m12?
Had this problem yesterday but it went away after a few reboots with no explanation. Emailed CloudMQTT because I couldn’t ping the server from ANYWHERE but got no response.
Still can’t ping it but it appears to be working anyway - glad to know I am not the only one with this issue…
Ok, sorry for boombing this thread but I’ve been able to resolve it and hopefully this works for you in the future.
the problem was on the CloudMQTT side. After testing with some clients, etc, the system was not responding at all so I decided to go with a basic test: Restart the Instance.
Are you on m12.cloudmqtt.com? They’ve been having a lot of issue with that server lately. It would be nice if they listed it on their status page but the only time you see anything about it is if it’s down.
Starting to think I might have to set up mosquitto…
I’m getting the same error as posted by kevince52. But I’m running mosquitto private broker. I also have ssl set up for HA http. And I’m also trying to set up certificates for mosquitto.
Hi all… I have had the same problem 6 months later! with cloud MQTT and with AWS. I have tried EVERYTHING!
i even fresh installed rasbian. I am wondering if it is a router issue since I seem to be having issues even with settign up a basic mosquitto setup.