Skip to Content

Unable to connect to MQTT broker in SAP IoT cockpit

Oct 11, 2017 at 01:59 PM


avatar image
Former Member

Hi All,

I have paho client installed in my laptop and like to send some data via the paho client to check the same in the IoT cockpit.

Scenario : My laptop is connected to wireless internet connection with firewalls turned off.I have created a device under MQTT network in SAP IoT cockpit with the details given below


Mac address : AR-2C-6D-52-9F-97

label : paho_client_1

Above details are respective to my laptop connections

Then i have downloaded the device certificates.

In paho client i have given the below details

server URI : ssl://<host>:1883

Client ID : AR-2C-6D-52-9F-97

Under options i have given the location of the

keystore location : keystore location

keystore password : pasted the generated password

trust store location :C:\Program Files (x86)\Java\jre1.8.0_144\lib\security/cacerts
trust store passord :any

I am unable to connect from paho client to sap iot cockpit . I am getting the following error

"org.eclipse.paho.client.mqttv3.MqttException: Unable to connect to server"

How to check the same ?

1.jpg (30.8 kB)
2.jpg (94.0 kB)
3.jpg (76.2 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Anton Levin
Oct 11, 2017 at 02:18 PM

Hello Deepan, port number should be 8883 and not 1883. Please, check with the tutorial [1]

Regards, Anton


Show 3 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thanks Anton,
Now i am able to connect and publish data but i am unable to see the gauge or data in cockpit.Any idea what might be the problem be and also Is there any where i can check the logs of why it has not displayed?

Datamodel file has more configaddr but i am only publishing only for 1 and 2

{"measureIds" :[1,2],"values":["75",30"],"profileId":990,"logNodeAddr":2}

4.jpg (101.6 kB)
5.jpg (204.3 kB)
6.jpg (110.4 kB)

Dear Deepan,

please familiarize yourself with the Community Rules of Engagements [1] and especially with #13 do not hijack - a current question is supposed to be answered. Resolution is - wrong port number used. This leads to #8 - be responsive.


Anton (Moderator)


P.S. Regarding your follow-up question, I would suggest opening a customer ticket, providing your instance ID, so that colleagues could have a closer look, analyze and understand what might went wrong.

Former Member

Thanks , Sorry for the mistake i will contact SAP