MQTT connection refused to eu.thethingsnetwork

Hi I tried connecting using:
mosquitto_sub -d -h eu.thethings.network -t "+/devices/+/events/activations" -u rascalmkrwan1300 -P ttn-account-61B5402EBC3777F80F0C03123458396F -v
(I have changed the Appkey for security)

And I get:
Client (null) sending CONNECT
Client (null) received CONNACK (5)
Connection error: Connection Refused: not authorised.
Client (null) sending DISCONNECT

(Have migrated the end device to a new cluster)
I can see that my data is being received in live data

I read: [https://www.thethingsnetwork.org/docs/applications/mqtt/quick-start/index.htm]

mosquitto_sub -h <Region>.thethings.network -t "+/devices/+/events/activations" -u "<AppID>" -P "<AppKey>" -v

I used End device ID for AppID - (correct?)

Should this be in quotes? “” rascalmkrwan1300 or"rascalmkrwan1300" ?

Elsewhere in the forum someone said: the AppKey starts with: ttn-account
I got the info from my console page
Any advice please.
Thanks
Russell

Do you mean TTS CE aka v3? If so and given you have the device showing live data, the application will have to be on v3, so that’s what you need to connect to.

That link comes up as 404 so you must have read it a while back.

Here’s the documentation (linked at the bottom of the console page that shows the MQTT connection info you need anyway): https://www.thethingsindustries.com/docs/integrations/mqtt/

They would have up until this year, then we’d start saying it starts NNSXS for v3

As above, the v3 console gives the correct address, username and quick access to the API key for a password.

Thanks for the reply. I read the link minutes ago, so I must have copied it incorrectly:
https://www.thethingsnetwork.org/docs/applications/mqtt/quick-start/index.html
(sorry, left out the end ‘l’ in html)

I understood that’s what I was connecting to?
Can you advise further.
Thanks

I think I already have by linking to the correct documentation and making the observation about the v3 console showing the correct address, username and a link to get a password …

Ok , so I went to that page and generated a password. I now tried:
mosquitto_sub -d -h eu.thethings.network -t “+/devices/+/events/activations” -u “rascalmkrwan1300” -P “NNSXS.GFYRZEIW6PYEVHL7UNQX7HPKNHSVG7OGLXMFMJI.7APUUTQ3BDMIXJKYLLUVL3SFVUNVI2UPVOSANE7DX5Gzzzzz” -v
So now I’m using the mqtt password - Is this correct?
I’m alsofollowing this video :Integrating Node RED with The Things Stack - YouTube
but in the console it reports:
mqtt-broker:mqttBroker] Connection failed to broker: mqtts://eu1.cloud.thethings.network:1883
Thanks again for your reply
Same issue
Do I need the double quotes around the appid and appkey
EDIT: I managed to connect using the steps in the video now - I think I misstyped. But I would like to try the console command to connect as well

Is this what you see on the v3 console?

Is this what you see on the v3 console?

Is this in the documentation?

Are you asking if using the MQTT password for MQTT is correct?

You could try it right now rather than wait on an answer.

I don’t use the command line, I use one of the GUI apps or Python, so I honestly don’t know without looking if up on the Mosquitto website …

I meant should I have I used the appID of the device , rather than the mqtt one - but that’s probably a silly question. I’ve tried with and without quotes. Anyway I am seeing data on the node-red gui so that’s getting somewhere. Ultimately I wanted to sent to thingspeak. Also I previously was sending to thinger.io data buckets, which stopped working (maybe required an update)
Thanks again - think I was looking in the main app console page not in the dedicated mqtt settings.
Edit: - Now I get: all subscription requests were denied - Progress, I guess

:thinking: in that case why not just use an Integration (see under webhooks) if that is what all the mqtt kerfufll is heading to? :wink:

Did you see my comment above about “where in the documentation is that” …

Hi - in the example at:
https://www.thethingsnetwork.org/docs/applications/mqtt/quick-start/index.html
I shows:

mosquitto_sub -h <Region>.thethings.network -t '+/devices/+/events/activations' -u '<AppID>' -P '<AppKey>' -v

image

Hi - ok will look at that. I’m new at this.

Why do you keep looking at the v2 documentation??

Ok, forgive me I thought that was current. Is the url now https://www.thethingsindustries.com/

Sorry, no, don’t do forgiveness, only do people getting things working.

So, for the THIRD time:

:wink: Ok, so thanks for that. Anyway, I am now able to send my MKRWAN 1300 data (temperature) to Thingspeak.
While you are in a helpful mood - May I ask (concerning a gateway):
If I can’t get hold of the password/login info for a gateway that I have. ( A friend gave me the hardware and set it up and is since no longer about). If I need to migrate or update settings: Can I recreate the gateway on the new cluster, or will the hardware (MAC address or EUI) recognize it as pre-existing and prevent this? (Mikrotik Lora 8)

V3 gateways are independent of V2 gateways. As long as the EUI has not been registered on V3 you can register a new gateway with that EUI.

Factory reset - because you HAVE to be able to login to set the new server address.

If you have more questions on this, can you start a new topic as gateways aren’t much to do with MQTT

Thanks for replies. will do