cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

Unable to connect to public MQTT server

hujingrui
13-Aquamarine

Unable to connect to public MQTT server

Hi i am trying to connect thingworx to a public mqtt broker.

 

I have install the thingworx mqtt extension and have use the mqtt template to create a mqtt thing.

However, in configuration when i input test.mosquitto.org or even 5.196.95.208. it still will not connect.

 

I have tried this both on my school's thingworx and the free trial webhosted thingworx but the result is the same

 

Please help.

ACCEPTED SOLUTION

Accepted Solutions
slangley
23-Emerald II
(To:slangley)

Hi @hujingrui.

 

The 30-day trial versions hosted by PTC have a number of restrictions, and since these are trials, configuration changes at the network level are not permitted.

 

It would be best for you to engage with your school's network engineering team to troubleshoot the connectivity issue.  There is no way within ThingWorx to do a ping test, though ping is usually blocked, which is why I was suggesting telnet.

 

Regards.

 

Sharon

View solution in original post

5 REPLIES 5
slangley
23-Emerald II
(To:hujingrui)

Hi @hujingrui.

 

Have you tested using telnet from the ThingWorx server to eliminate the possibility of a firewall issue:

 

telnet test.mosquitto.org 1883

 

Note:  your port may be different.

 

Have you validated you are using the right port?  Have you checked the logs for some insight into the cause of the failure?

 

Regards.

 

--Sharon

hujingrui
13-Aquamarine
(To:slangley)

I do not have access to the physical thingworx server. Only thingworx composer on my web browser.

1. Can you advise me on how to telnet from thingworx composer? 

 

2. Which port does the thingworx client use?

I have confirm that the broker port set on thingworx mqtt thing is correct eg 1883.

 

3. The logs does not say much except no response from the server but on the server there does not seem to be an issue. 

*** I thought it might be an issue on the school's thingworx so i tried the same steps on the 30 days trial webhosted version but the same issue. 

Maybe the webhosted version's firewall is blocking it as well?

Perhaps you can help me solve the web-hosted version first before i try on the school's thingworx 

slangley
23-Emerald II
(To:slangley)

Hi @hujingrui.

 

The 30-day trial versions hosted by PTC have a number of restrictions, and since these are trials, configuration changes at the network level are not permitted.

 

It would be best for you to engage with your school's network engineering team to troubleshoot the connectivity issue.  There is no way within ThingWorx to do a ping test, though ping is usually blocked, which is why I was suggesting telnet.

 

Regards.

 

Sharon

hujingrui
13-Aquamarine
(To:slangley)

i could not telnet. Most probably it is a firewall issue. 

slangley
23-Emerald II
(To:hujingrui)

Hi @hujingrui.

 

Have you checked the server firewall to be sure that's not the cause?  If that doesn't appear to be the issue, you should be able to engage with your network engineering team.  They will have the ability to trace the connection to determine where it is failing and make the needed firewall changes (assuming they're approved).

 

Regards.

 

--Sharon

 

 

Announcements


Top Tags