Issue using Azure IoT Hub

How to configure Meshlium or use the Manager System
Post Reply
amolina
Posts: 13
Joined: Wed Jun 12, 2019 8:40 am
Company: Cosentino

Issue using Azure IoT Hub

Post by amolina » Tue Jul 23, 2019 2:56 pm

Hello,

My Meshlium is sending data to Azure IoT Hub, but mysteriously it stops working. It is the second time it happens in a month. I can see these errors in the log:

Code: Select all

java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
java.lang.Thread.run(Thread.java:745)
java.lang.IllegalStateException: The MQTT connection is currently closed. Call open() before attempting to receive a message.: The MQTT connection is currently closed. Call open() before attempting to receive a message.
com.microsoft.azure.iothub.transport.mqtt.MqttIotHubConnection.receiveMessage(MqttIotHubConnection.java:245)
com.microsoft.azure.iothub.transport.mqtt.MqttTransport.handleMessage(MqttTransport.java:256)
com.microsoft.azure.iothub.transport.IotHubReceiveTask.run(IotHubReceiveTask.java:25)
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
I stopped the service and started it, previous errors reappeared but now it works again.


What could be the issue?

Thanks.

libelium-dev
Posts: 27967
Joined: Mon Sep 28, 2009 1:06 pm

Re: Issue using Azure IoT Hub

Post by libelium-dev » Wed Jul 24, 2019 11:11 am

Hi,

What is the manager system version? Could you please update Meshlium to v4.1.6 and let us know if the problem occurs again?

Regards

amolina
Posts: 13
Joined: Wed Jun 12, 2019 8:40 am
Company: Cosentino

Re: Issue using Azure IoT Hub

Post by amolina » Tue Aug 27, 2019 6:13 pm

I updated the Meshlium to v4.1.6. but the issue is still present. After a few days, stop sending data to Azure.

libelium-dev
Posts: 27967
Joined: Mon Sep 28, 2009 1:06 pm

Re: Issue using Azure IoT Hub

Post by libelium-dev » Wed Aug 28, 2019 8:06 am

Hi,

Please share the Azure log with us to be able to know more information about the issue. You can obtain the logs by connecting to the Meshlium using an FTP client and these credentials:
- user: log
- password: libelium2014

Regards

amolina
Posts: 13
Joined: Wed Jun 12, 2019 8:40 am
Company: Cosentino

Re: Issue using Azure IoT Hub

Post by amolina » Wed Aug 28, 2019 9:22 am

"Platform Status" was in red. I restarted the service using the button near to "Plaform Status" and it started working again. Then I downloaded the log file, It is working but there are many errors; https://grupocosentino-my.sharepoint.co ... w?e=cUsH2n

Next time I will download the file before restarting the service.

libelium-dev
Posts: 27967
Joined: Mon Sep 28, 2009 1:06 pm

Re: Issue using Azure IoT Hub

Post by libelium-dev » Wed Sep 04, 2019 9:49 am

Hi,

Apologies for the delay answering.

Please set Log Level to DEBUG in the Azure cloud connector settings and then start the connector again. If after some days, it stops working again please send us the log file to know more information about the issue.

On the other hand, did you try to send data through another protocol (https or amqps)? Does it stop too?

Regards

amolina
Posts: 13
Joined: Wed Jun 12, 2019 8:40 am
Company: Cosentino

Re: Issue using Azure IoT Hub

Post by amolina » Wed Sep 11, 2019 11:05 am

I attach a new file with errors: https://grupocosentino-my.sharepoint.co ... A?e=tCamB8

Now I set Log Level to DEBUG and I changed to https.

libelium-dev
Posts: 27967
Joined: Mon Sep 28, 2009 1:06 pm

Re: Issue using Azure IoT Hub

Post by libelium-dev » Wed Sep 11, 2019 2:39 pm

Hi,

It seems that https protocol isn't used. The log shows that meshlium is trying to send data through mqtt protocol. Please stop the azure connector, save the changes with https selected and then start the connector again.

Regards

amolina
Posts: 13
Joined: Wed Jun 12, 2019 8:40 am
Company: Cosentino

Re: Issue using Azure IoT Hub

Post by amolina » Thu Oct 03, 2019 3:33 pm

Hello,

After 20 days using the HTTPS protocol it has failed again, the gateway has stopped uploading data to Azure.

The configuration is the one shown in the image:
Image

I get errors in the log tab:
Image


You can download the log files here: https://grupocosentino-my.sharepoint.co ... A?e=NGAKND.


I pressed the Stop button, then pressed again to start, then started uploading data to Azure.

libelium-dev
Posts: 27967
Joined: Mon Sep 28, 2009 1:06 pm

Re: Issue using Azure IoT Hub

Post by libelium-dev » Tue Oct 08, 2019 10:25 am

Hi,

Please fill the RMA form and we will contact you to solve the issue.

Regards

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests