Difference between MQTT Integration, MQTT Forwarder and mosquitto.conf

Hello, I’m configuring a LoRaWAN network as part of a research work at my university and I’ve been struggling a bit trying to differentiate the concepts of MQTT Integration, MQTT Forwarder and mosquitto.conf.

  1. In what situations should I modify the chirpstack-mqtt-forwarder.toml file? I haven’t found it and I’ve been able to add gateways and end nodes correctly, so what is it for?

  2. I understand that the server comes installed with a broker by default. Is this the one located in the path configuration/mosquitto/config/mosquitto.conf? If I change this config file (add an authentication for example) I affect the mqtt forwarder?

  3. If I am going to use the server’s local broker, do I need to add MQTT integration?

I’ve installed the networkserver using Docker Compose.

I look forward to your response and thank you for your time.

Understandable confusion for sure.

The MQTT Forwarder / Gateway Bridge:

The MQTT forwarder and the gateway bridge both server the same purpose, to connect your gateways to the MQTT broker. The MQTT Forwarder is actually just a newer version of the gateway bridge, designed to be more lightweight so it can run on gateways with less resources. Considering you haven’t changed any config and everything is working I assume you are using the gateway bridge to connect your gateways, if so you can ignore any mqtt-forwarder config.

Mosquitto.conf / MQTT broker:

The MQTT broker is the heart of Chirpstack, the gateways post to the MQTT broker, and Chirpstack subscribes to it to receive the events (lorawan uplinks). The mosquitto.conf is the configuration file for the MQTT broker, adding authentication to this will make it required for gateways (or at least your gateway-bridge) and chirpstack to use that authentication to connect.

MQTT integration:

This is a confusing one because of the labelling, a lot of people have this issue and I’ve said before that the description needs to be changed. The photo you have shared is not an integration in the sense you would expect, it is just a button to create client certificates for gateways if you have configured TLS for your MQTT broker by following this guide: Mosquitto TLS configuration - ChirpStack open-source LoRaWAN® Network Server documentation . Rather the MQTT integration you would expect (where it forwards decrypted MQTT data to a broker to be used for integrations) is configured in your chirpstack.toml and is on by default. If you subscribe to your MQTT broker now, you should see topics starting with “application/…”, these are the integration events, and are the decrypted versions of “<region_prefix>/…” events which are messages directly to/from the gateway bridge and are still encrypted using your LoRaWAN session keys.

Hopefully none of that was too confusing, let me know if you need more clarification