Skip to content

Commit 6e762e1

Browse files
committed
mqtt: fix new DNS
1 parent 65530b0 commit 6e762e1

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

docs/tools/mqtt-broker.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ description: This document shows how to exchange simple messages using the MQTT
99
MQTT (MQ Telemetry Transport) is a protocol designed on top of TCP/IP and based
1010
on a publish/subscribe principle.
1111

12-
1312
<figure style="text-align:center">
1413
<img src="{{ '/assets/images/docs/mqtt/' | relative_url}}pub-sub-model.png" style="width:500px;"/><br/>
1514
<figcaption>The MQTT publish subscribe model (<a href="https://www.researchgate.net/publication/327661439_The_Addition_of_Geolocation_to_Sensor_Networks">Source</a>)</figcaption>
@@ -24,22 +23,23 @@ The [Eclipse mosquitto project](https://mosquitto.org/) provide an open-source
2423
MQTT broker as well as a C library for implementing clients and the
2524
`mosquitto_pub` and `mosquitto_sub` command line interface clients.
2625

27-
The FIT IoT-LAB testbed provides an instance of the Eclipse mosquitto broker
28-
at **mqtt.iot-lab.info**. This instance is public and only
29-
**port 8883 with TLS encryption** can be used.
26+
The FIT IoT-LAB testbed provides an instance of the Eclipse mosquitto broker. This instance is public and only **port 8883 with TLS encryption** can be used.
3027

3128
## Connect to the IoT-LAB MQTT broker
3229

3330
**Important things:**
3431

35-
> Any FIT IoT-LAB user can connect to mqtt4.iot-lab.info with its personal
32+
> Any FIT IoT-LAB user can connect to MQTT broker with its personal
3633
> FIT IoT-LAB credentials and a certificate file that is available either here
3734
> or on each SSH frontend in /opt/iot-lab-ca.pem.
3835
> Authenticated FIT IoT-LAB users can only have access to `iotlab/<login>`
3936
> topics and sub-topics. This ensures confidentiality between users when
4037
> exchanging MQTT messages. Only TLS encryption on port 8883 is allowed on the
4138
> broker.
4239
40+
* MQTT broker is accessible on IPv4 at **mqtt4.iot-lab.info** on port 8883
41+
* MQTT broker is accessible on IPv6 at **mqtt6.iot-lab.info** on port 8883
42+
4343
### From your local computer
4444

4545
1. Download and install the mosquitto-clients by following the installation
@@ -58,9 +58,9 @@ at **mqtt.iot-lab.info**. This instance is public and only
5858

5959
2. Download the certificate file from [here]({{ site.baseurl }}{% link assets/misc/docs/mqtt/iot-lab-ca.pem %}).
6060

61-
3. Connect to the broker using one of the mosquitto-clients command line:
61+
3. Connect to the broker via IPv4 using one of the mosquitto-clients command line:
6262
```sh
63-
$ mosquitto_sub --cafile <path-to>/iot-lab-ca.pem -h mqtt.iot-lab.info -p 8883 -u <iotlab-login> -P <iotlab-passwd> -t iotlab/<iotlab-login>/test
63+
$ mosquitto_sub --cafile <path-to>/iot-lab-ca.pem -h mqtt4.iot-lab.info -p 8883 -u <iotlab-login> -P <iotlab-passwd> -t iotlab/<iotlab-login>/test
6464
```
6565

6666
### From an SSH frontend
@@ -89,9 +89,9 @@ at **mqtt.iot-lab.info**. This instance is public and only
8989
To encrypt the communication with the broker, the certificate file is located
9090
in `/opt/iot-lab-ca.pem`.
9191

92-
3. Connect to the broker using one of the mosquitto-clients command line:
92+
3. Connect to the broker via IPv4 using one of the mosquitto-clients command line:
9393
```sh
94-
login@saclay:~$ mosquitto_sub --cafile /opt/iot-lab-ca.pem -h mqtt.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test
94+
login@saclay:~$ mosquitto_sub --cafile /opt/iot-lab-ca.pem -h mqtt4.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test
9595
```
9696
**Note:** you don’t need to provide your credentials on the command line
9797
because they are retrieved from the config files you previously edited.
@@ -120,7 +120,7 @@ MQTT messages between the Saclay SSH frontend and your local computer.
120120
1. From your local computer, run `mosquitto_sub` to subscribe to the
121121
`iotlab/<iotlab-login>/test` topic:
122122
```
123-
$ mosquitto_sub --cafile <path-to>/iot-lab-ca.pem -h mqtt.iot-lab.info -p 8883 -u <iotlab-login> -P <iotlab-passwd> -t iotlab/<iotlab-login>/test
123+
$ mosquitto_sub --cafile <path-to>/iot-lab-ca.pem -h mqtt4.iot-lab.info -p 8883 -u <iotlab-login> -P <iotlab-passwd> -t iotlab/<iotlab-login>/test
124124
```
125125
The command is now waiting for any messages published on the
126126
`iotlab/<iotlab-login>/test` topic. **Keep it open**
@@ -133,12 +133,12 @@ MQTT messages between the Saclay SSH frontend and your local computer.
133133
`mosquitto_pub`:
134134
- Send one message at a time:
135135
```
136-
login@saclay:~$ mosquitto_pub --cafile /opt/iot-lab-ca.pem -h mqtt.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test -m "Hello FIT IoT-LAB"
136+
login@saclay:~$ mosquitto_pub --cafile /opt/iot-lab-ca.pem -h mqtt4.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test -m "Hello FIT IoT-LAB"
137137
```
138138
You should see the message arrive in the `mosquitto_sub` command running on your local computer.
139139
- Run `mosquitto_pub` in interactive mode using the `-l` option:
140140
```
141-
login@saclay:~$ mosquitto_pub --cafile /opt/iot-lab-ca.pem -h mqtt.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test -l
141+
login@saclay:~$ mosquitto_pub --cafile /opt/iot-lab-ca.pem -h mqtt4.iot-lab.info -p 8883 -t iotlab/<iotlab-login>/test -l
142142
Hello FIT IoT-LAB
143143
```
144144
All messages typed in the terminal are sent after pressing Enter to the

0 commit comments

Comments
 (0)