OTAA failed / Debugging device activation OTAA issues

@Gal @julien please note that there already is a v1.2.0 version of I-CUBE-LRWAN. Maybe that is worth trying?

I did try that version and after setting the connection data in commissioning.h and downloading it to my MCU nothing came through.

In fact, I have the same problem as you, whether the problem is solved now or not.

It is not resolved. I am using ABP whenever I need to test something.

Hello brocaar,
Why have I tried all the LoraWAN MAC versions and still have a join-request join-accept loop?

Hi @brocaar, thanks for your support.

Following the https://forum.loraserver.io/t/unable-to-receive-sensor-data-after-otaa/3428 thread, and after that uplink you see, the subsequent uplinks reach the “live lorawan frames” but they never reach the “live device data” tab.

As you can see here:

Can you help us understand what does this mean?

Thank you,
Best regards.
Miguel

Also having problems to OTAA join (with RN2483 and RHF76-052).

loraserver receives JoinRequest and issues JoinAccept:
loraserver1

gateway looks like this:
gateway/+/rx {“rxInfo”:{“mac”:“xxxxxxxxxxxxxxxxxx”,“timestamp”:1913704108,“frequency”:868299987,“channel”:0,“rfChain”:0,“crcStatus”:1,“codeRate”:“4/5”,“rssi”:-68,“loRaSNR”:9,“size”:23,“dataRate”:{“modulation”:“LORA”,“spreadFactor”:7,“bandwidth”:125},“board”:0,“antenna”:0},“phyPayload”:“ABAxAdB+1bNwQJ27/SrpMiLnbZeG51k=”}
gateway/+/tx {“token”:5804,“txInfo”:{“mac”:“xxxxxxxxxxxxxxxxxx”,“immediately”:false,“timestamp”:1918704108,“frequency”:868299987,“power”:14,“dataRate”:{“modulation”:“LORA”,“spreadFactor”:7,“bandwidth”:125},“codeRate”:“4/5”,“iPol”:true,“board”:0,“antenna”:0},“phyPayload”:“IOmnU702SgGjqNSTpJ+02PI=”}
gateway/+/ack {“mac”:“xxxxxxxxxxxxxxxxxxx”,“token”:0}

Hence, the nodes never receive a join accept.

ABP works fine here. And OTAA works fine with TTN but not here.

Using LoRaWAN 1.0.1 and 1.0.2, respectively, and https://github.com/things4u/ESP-1ch-Gateway-v5.0.

Any hints? Thanks a lot.

Good day!
I have a strange server behavior. We have two devices(1.0.2, OTAA) that, when turned on, send a message to join, you can see that the server responds to their acceptance, then the first messages are transmitted, and everything goes as expected, except for three things: the activation tab does not show activation keys , but there are information of battery and the device margin and third, messages on the mqtt are not transmitted!

мар 11 15:12:47 lws2 lora-app-server[970]: time="2019-03-11T15:12:47+03:00" level=info msg="js: request received" message_type=JoinReq receiver_id=7665676173693131 sender_id=000000 transaction_id=787587301
мар 11 15:12:47 lws2 lora-app-server[970]: time="2019-03-11T15:12:47+03:00" level=info msg="device-keys updated" dev_eui=393337386b375e0c
мар 11 15:12:47 lws2 lora-app-server[970]: time="2019-03-11T15:12:47+03:00" level=info msg="js: sending response" message_type=JoinAns receiver_id=000000 result_code=Success sender_id=7665676173693131 transaction_id=787587301
мар 11 15:13:03 lws2 lora-app-server[970]: time="2019-03-11T15:13:03+03:00" level=info msg="device updated" dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 lora-app-server[970]: time="2019-03-11T15:13:03+03:00" level=info msg="handler/mqtt: publishing message" qos=0 topic=application/1/device/393337386b375e0c/status
мар 11 15:13:09 lws2 lora-app-server[970]: time="2019-03-11T15:13:09+03:00" level=info msg="handler/influxdb: status measurements written" dev_eui=393337386b375e0c

мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="packet(s) collected" dev_eui=393337386b375e0c gw_count=1 gw_ids=aad00dba19000013 mtype=JoinRequest
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="device-queue flushed" dev_eui=393337386b375e0c
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="device-session saved" dev_addr=0186e52a dev_eui=393337386b375e0c
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="device-activation created" dev_eui=393337386b375e0c id=11764
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="device updated" dev_eui=393337386b375e0c
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="gateway/mqtt: publishing downlink frame" qos=0 topic=gateway/aad00dba19000013/tx
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="downlink-frames saved" dev_eui=393337386b375e0c token=44034
мар 11 15:12:47 lws2 loraserver[971]: time="2019-03-11T15:12:47+03:00" level=info msg="backend/gateway: downlink tx acknowledgement received" gateway_id=aad00dba19000013
мар 11 15:12:53 lws2 loraserver[971]: time="2019-03-11T15:12:53+03:00" level=info msg="gateway/mqtt: gateway stats packet received" gateway_id=21000000080e0e38
мар 11 15:12:53 lws2 loraserver[971]: time="2019-03-11T15:12:53+03:00" level=info msg="gateway updated" gateway_id=21000000080e0e38
мар 11 15:12:53 lws2 loraserver[971]: time="2019-03-11T15:12:53+03:00" level=info msg="gateway/mqtt: publishing gateway configuration" qos=0 topic=gateway/21000000080e0e38/config
мар 11 15:12:53 lws2 loraserver[971]: time="2019-03-11T15:12:53+03:00" level=info msg="metrics saved" aggregation="[MINUTE HOUR DAY MONTH]" name="gw:21000000080e0e38"
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="rx info sent to network-controller" dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="pending mac-command deleted" cid=LinkCheckReq dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="device gateway rx-info meta-data saved" dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="device-session saved" dev_addr=0186e52a dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="requesting device-status" dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="pending mac-command block set" cid=LinkCheckReq commands=1 dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="pending mac-command block set" cid=DevStatusReq commands=1 dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="pending mac-command block set" cid=RXTimingSetupReq commands=1 dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="gateway/mqtt: publishing downlink frame" qos=0 topic=gateway/aad00dba19000013/tx
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="device-session saved" dev_addr=0186e52a dev_eui=393337386b375e0c
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="downlink-frames saved" dev_eui=393337386b375e0c token=22153
мар 11 15:12:57 lws2 loraserver[971]: time="2019-03-11T15:12:57+03:00" level=info msg="backend/gateway: downlink tx acknowledgement received" gateway_id=aad00dba19000013
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway/mqtt: uplink frame received"
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="rx info sent to network-controller" dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="pending mac-command deleted" cid=DevStatusReq dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="dev_status_ans answer received" battery=255 dev_eui=393337386b375e0c margin=31
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="pending mac-command deleted" cid=RXTimingSetupReq dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="rx_timing_setup request acknowledged" dev_eui=393337386b375e0c rx_delay=1
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="pending mac-command deleted" cid=LinkCheckReq dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="device gateway rx-info meta-data saved" dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="device-session saved" dev_addr=0186e52a dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="pending mac-command block set" cid=LinkCheckReq commands=1 dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway/mqtt: publishing downlink frame" qos=0 topic=gateway/aad00dba19000013/tx
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="device-session saved" dev_addr=0186e52a dev_eui=393337386b375e0c
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="downlink-frames saved" dev_eui=393337386b375e0c token=32355
мар 11 15:13:03 lws2 loraserver[971]: time="2019-03-11T15:13:03+03:00" level=info msg="backend/gateway: downlink tx acknowledgement received" gateway_id=aad00dba19000013
мар 11 15:13:07 lws2 loraserver[971]: time="2019-03-11T15:13:07+03:00" level=info msg="gateway/mqtt: gateway stats packet received" gateway_id=0000985dad86df5b
мар 11 15:13:07 lws2 loraserver[971]: time="2019-03-11T15:13:07+03:00" level=info msg="gateway updated" gateway_id=0000985dad86df5b
мар 11 15:13:07 lws2 loraserver[971]: time="2019-03-11T15:13:07+03:00" level=info msg="gateway/mqtt: publishing gateway configuration" qos=0 topic=gateway/0000985dad86df5b/config

мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.92:52859" data="ADExaXNhZ2V2DF43azg3MzmjkYUpLsc=" mac=aad00dba19000013
мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/rx
мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.159:34685" data="ADExaXNhZ2V2DF43azg3MzmjkYUpLsc=" mac=0000985dad86df5b
мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/0000985dad86df5b/rx
мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="backend: downlink packet received" topic=gateway/aad00dba19000013/tx
мар 11 15:12:47 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:47+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/ack
мар 11 15:12:53 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:53+03:00" level=info msg="gateway: stat packet received" addr="192.168.111.74:42690" mac=21000000080e0e38
мар 11 15:12:53 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:53+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/21000000080e0e38/stats
мар 11 15:12:53 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:53+03:00" level=info msg="backend: config packet received" topic=gateway/21000000080e0e38/config
мар 11 15:12:53 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:53+03:00" level=warning msg="gateway: configuration was not applied, gateway is not configured for managed configuration" mac=21000000080e0e38
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.92:52859" data="QCrlhgEAAAAAu439aQE=" mac=aad00dba19000013
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/rx
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.159:34685" data="QCrlhgEAAAAAu439aQE=" mac=0000985dad86df5b
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/0000985dad86df5b/rx
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="backend: downlink packet received" topic=gateway/aad00dba19000013/tx
мар 11 15:12:57 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:12:57+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/ack
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.92:52859" data=QCrlhgEAAQAAOoUyumnuJE83 mac=aad00dba19000013
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.92:52859" data=QCrlhgEAAQAAOoUyumnuJE83 mac=aad00dba19000013
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/rx
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/rx
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.74:42690" data=QCrlhgEAAQAAOoUyumnuJE83 mac=21000000080e0e38
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/21000000080e0e38/rx
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="gateway: rxpk packet received" addr="192.168.111.159:34685" data=QCrlhgEAAQAAOoUyumnuJE83 mac=0000985dad86df5b
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/0000985dad86df5b/rx
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: downlink packet received" topic=gateway/aad00dba19000013/tx
мар 11 15:13:03 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:03+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/ack
мар 11 15:13:07 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:07+03:00" level=info msg="gateway: stat packet received" addr="192.168.111.159:34685" mac=0000985dad86df5b
мар 11 15:13:07 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:07+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/0000985dad86df5b/stats
мар 11 15:13:07 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:07+03:00" level=info msg="backend: config packet received" topic=gateway/0000985dad86df5b/config
мар 11 15:13:07 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:07+03:00" level=warning msg="gateway: configuration was not applied, gateway is not configured for managed configuration" mac=0000985dad86df5b
мар 11 15:13:11 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:11+03:00" level=info msg="gateway: stat packet received" addr="192.168.111.92:52859" mac=aad00dba19000013
мар 11 15:13:11 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:11+03:00" level=info msg="backend: publishing packet" qos=0 topic=gateway/aad00dba19000013/stats
мар 11 15:13:11 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:11+03:00" level=info msg="backend: config packet received" topic=gateway/aad00dba19000013/config
мар 11 15:13:11 lws2 lora-gateway-bridge[976]: time="2019-03-11T15:13:11+03:00" level=warning msg="gateway: configuration was not applied, gateway is not configured for managed configuration" mac=aad00dba19000013

image

Hi, does anyone found a solution for this yet?

…disconnect (power off) the node for 24 hrs and then reconnect it.

Hi, we experienced a similar issue. Redis was out of memory (>1G) so we had to reinitialize Redis and allocate more memory. Some nodes are not able to rejoin. Is there a way to remove ‘old’ node sessions from redis? When we remove the node data from Lora app server and re-enter the node doesn’t rejoin, only after a manual reset.

1 Like

I’m having the issue where a device is stuck in a Join Request-Join Accept loop with a sensor made by Netvox.

Oddly, other Netvox sensors work OK and this sensor in particular works OK with ThingsNetwork and Loriot.io.

I have tried it with all versions of Lorawan supported by LoraServer, 1.0.0-1.1.0.

Apr 05 10:06:27 loraserver-1 loraserver[945]: time="2019-04-05T10:06:27Z" level=info 
msg="gateway/mqtt: uplink frame received"
Apr 05 10:06:27 loraserver-1 loraserver[945]: time="2019-04-05T10:06:27Z" level=info 
msg="gateway/mqtt: uplink frame received"
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="packet(s) collected" dev_eui=00137a1000000976 gw_count=2 
gw_ids="647fdafffe00744f, fcc23dfffe0f0d35" mtype=JoinRequest
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="device-queue flushed" dev_eui=00137a1000000976
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="device-session saved" dev_addr=0179f6df dev_eui=00137a1000000976
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="device-activation created" dev_eui=00137a1000000976 id=570
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="gateway/mqtt: publishing downlink frame" qos=0 
topic=gateway/647fdafffe00744f/tx
Apr 05 10:06:28 loraserver-1 loraserver[945]: time="2019-04-05T10:06:28Z" level=info 
msg="downlink-frames saved" dev_eui=00137a1000000976 token=24467

Please can you send it to me.
Thanks a lot.

Please does anyone found a solution to the joinRequest joinAccept loop without the activation of the device. I really need help.
Thanks a lot.

I have same issue BUT:
setting SF10 results in 100% joinAccept reception by end node
setting SF11 results in 50% joinAccept reception
setting SF12 results in 0% joinAccept reception and failure to join.

Tried using ABP with confirmed messages. Node sends packages with confirmation request. Again
SF10 - 100% confirmed
SF11 - 50% confirmed
SF12 - none is confirmed

Raising SF causes end node to fail receiving downlink packages. My end node is class A.

I suppose SF12 should be more stable…
What might be the reason?

Most likely SF12 is being rejected as the packets would be too illicitly long in time.

SF11 may be failing because they are so long in time that statistically some interference or time collisions may be happening before they are done.

Or there may be implementation bugs in your node that get triggered at higher spreading factors, for example wrong calculation of the transmit time leading to receiving at the wrong point in time.

Dear friends, I have a LoraWAN device. It’s a water-meter. It works on frequency 485.7MHz to 487.1MHz. When using OTAA, JoinAccept will use 506.1MHz or 506.5MHz. How can I change the frequency to 485.7Mhz - 487.1Mhz?

Hello everyone,
How do I change the LoRaWAN mac versions? I cannot seem to find the device- profile. Where do I start looking?

In the device-profile :wink:

image