MQTT Broker - choice of server

Hi everyone,

Where are you hosting your MQTT brokers? I’m trying to use Google IoT with MQTT bridge but the connection is so difficult and it is working yet. Is there a better approach? Sorry if it is a repeated topic.

On a local machine (linux) at the moment…even though my OpenHAB is windows. But I do see there’s a windows MQTT server also.

Given how much traffic I’m now sending over it, local is best for me…and it’s pretty lightweight and easy to configure.

1 Like

A local instance of Mosquitto running in a Docker container. I don’t have any need to communicate with the broker from outside my network and I’d rather not have to depend on a cloud service for what is essentially local network traffic.

I know a number of people on this forum use CloudMQTT. The free tier is usually adequate for most home automation purposes.

1 Like

Mosquitto on the same server running OH. Using it with Owntracks, so accessible through a reverse proxy.

1 Like

Local mosquitto, on the same machine that is running OpenHAB

1 Like

I am running my MQTT server on my Synology DiskStation as a Docker container. I prefer to have it installed within my local network.

1 Like

Running Mosquitto locally here, I am trying to keep as much as possible in-house so that I am not reliant on either my internet connection or a 3rd party service.

I do also have my local Mosquitto instance talking to a CloudMQTT instance, which I did use for OwnTracks, but I found that OwnTracks wasn’t reliable on my Huawei phone, so that’s actually not really being used (but I’ll keep the CloudMQTT instance configured for the moment just in case I find I do have a better usage case for it)

2 Likes

as seen here, there’s loads of people running mosquitto as a broker, I might even bet most of them are using it from within openHABian.
I installed the broker (and the MySQL/MariaDB persistence) on my NAS (Synology). It’s already running 24/7 and so I don’t have more activity on the Pi’s SD Card.

PS: I changed the topic a bit to make it more clear.

2 Likes

I am just now starting into MQTT and i see that openHAB has a built in broker? Is there any reason to use this over mosquitto? I am new to MQTT and want to make the best choice long term. From a design perspective i generally like to keep everything under one hood so to speak so the internal broker was intriguing but there is no documentation on it so didn’t know if that meant it was new or dead.

It’s less work. It is far easier to set up. It is one less application you need to keep up with.

On-the-other-hand, Mosquitto is more mature and has a lot more options.

Personally, I’d start out with the built in broker and when/if you run into something we need to do that it won’t handle then look into spinning up a Mosquitto.

It’s new as of OH 2.4 which was just released on Monday.

just the answer i was looking for will start with the built in broker. I have been running 2.4 for awhile now as part of the testing branch.

Mosquitto is a c++ developed application with a high throughput and minimal memory consumption. A badly designed c/c++ application might result in hard to debug crashes, but the maturity of the project and no known crash while I was using it speaks for it.

Moquette, the embedded broker, is or was as well as Mosquitto an Eclipse project. It depends and is based on some external libraries (netty mostly) which are quite mature as well, but had a serious memory leak until mid of this year (resolved in the used version).

Feature wise they are equally good, both allow credentials, encrypted access, acls.

Personally I would decouple components if possible and tend towards Mosquitto.