Jump toUpdate content
How to use the logging Kickstart
The logging Kickstart provides a database and a dashboard to store and visualize log messages transmitted through your IoT Hub.
It will setup and configure the following software on a Scaleway Instance:
- ElasticSearch: a document database tailored for log storage
- Kibana: a powerful log visualization dashboard
- Bridge: a very simple, Scaleway-made, MQTT client to store messages in ElasticSearch
Select the IoT Hub and device to use with the Kickstart.Important:
Currently only devices supporting insecure connections are allowed for this IoT Kickstart.
Choose the geographical region to deploy your Kickstart.
Set a password for the Kickstart’s dashboard.
Click Create a Kickstart to launch the installation of the software stack.
The kickstart setup process will insert a first log item in the database to make sure it is up and running.
The bridge will connect to your IoT Hub and subscribe to
# (all topics, more information about MQTT topics here.
Any valid message published on your IoT Hub will be stored as a document in the ElasticSearch database.
If the message payload is a UTF-8 encoded string, there are 3 possibilities:
- payload is a number: this number will show up in a
valuefield of the document
- payload is a JSON encoded string: the first order JSON fields will be stored in the document
- payload is any other string: this string will show up in a
payloadfield of the document The bridge also adds a
timestampfield to any document.
Click IoT Hub in the IoT Station section of the side menu. The list of your IoT Hubs displays.
Click the name of the IoT Hub you want to configure. The hub’s overview page displays.
Click Devices to display the configuration of the device.
Click Add devices in the devices tab. The Create a Device wizard displays.
Enter a name for the device and allow insecure connections.
Click Add a Device to your Hub. The details of the device display. Take a note of the Device ID:
Open a terminal window on your local computer and type the following command:
mosquitto_pub -h iot.fr-par.scw.cloud -i <device id> -t home/bedroom/temperature -m 19.4Note:
iot-fr-par.scw.cloudmay vary, you find your endpoint on the Hub’s network page.
The command above contains the following elements:
-h: The endpoint or host of your IoT Hub. You require it to communiciate with your hub.
-i: The device ID of your device. You can retrieve it from the Devices section of your hub.
-t: The thread to send your meesage to.
-m: The message containing the information you want to transmit.
Open a web browser and go to your Kickstarts dashboard (Kibana) available at
http://<your_kickstart_instance_ip>. Login using the user admin and the password set during the Kickstart creation.
Click «See more Icon», then Discover. The discover page displays. You should see an item matching the message you just sent.
For more information about Kibana features, see the official documentation.