# \[solved\] Migration from v2 to v3 give "device not found" depending on frequency

**URL:** <https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604>\
**Category:** The Things Stack v3\
**Created:** [May 11, 2021, 2:37pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604 "2021-05-11T14:37:07Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Raccoon](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/raccoon/32/35697_2.png) [@Raccoon](https://www.thethingsnetwork.org/forum/u/Raccoon)\
**Post date:** [May 11, 2021, 2:37pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/1 "2021-05-11T14:37:07Z")

</div>

Hello Everyone,  
I have some custom made moteino end user nodes with RFM95W that were sending data every 10 min since 1years and half on ttn v2. Today i decided to finally migrate everything to version 3.

So thanks to many post on this forum I updated to rak2245 pi to ttn v3, success connected, receiving data…

My end user devices, i imported them manually in console (im in ABP) thanks to this post :

> [@How to Migrate ABP Devices from V2 to V3](https://www.thethingsnetwork.org/forum/t/how-to-migrate-abp-devices-from-v2-to-v3/43705):
>
> I’m writing this post as a quick draft that will be extended and eventually turned into a documentation page. warning Migrating existing ABP devices requires one of the following: Your gateway is connected to V3, or You update the device address (DevAddr) in your end device(s) with a new device address generated in the V3 console. This option may require flashing new firmware to the device. Read below instructions carefully. If you make a mistake it might not be possible to correct it l…

All i did on my end device was reseting via the RST pin, and it started working for 3 messages, i reached counter around 15/16 and it suddenly stopped working, then started working again for 3 messages, then again device not found for the next 5 messages, as example this node:

it reach **fc\_cnt 15** failed, device not found

 ![Screenshot 2021-05-11 at 16.19.10](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/8/b/8b5f85a013219482499c100562e4ad04de05c939.png)

10 min later, at next call from the same node, **fc\_cnt 16** : worked 🤔

 ![Screenshot 2021-05-11 at 16.18.54](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/e/2/e2b94c227e4a4ac7116767d6f28d76f1b9433db5.png)

30 min later, another device not found from same node ( it worked for 17 and 18)

 ![Screenshot 2021-05-11 at 16.46.25](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/d/9/d91409109c94465b91174c825922c85fdc7b743e.png)

When it fail i get this error:

> ```
> "data": {
> "@type": "type.googleapis.com/ttn.lorawan.v3.ErrorDetails",
> "namespace": "pkg/gatewayserver",
> "name": "host_handle",
> "message_format": "host `{host}` failed to handle message",
> "attributes": {
> "host": "cluster"
> },
> "cause": {
> "namespace": "pkg/networkserver",
> "name": "device_not_found",
> "message_format": "device not found",
> "correlation_id": "4f88c2b31b9642029564c0548340048e",
> "cause": {
> "namespace": "pkg/networkserver/redis",
> "name": "no_uplink_match",
> "message_format": "no device matches uplink",
> "code": 5
> },
> "code": 5
> },
> "code": 5
> }, 
> 
> ```

I noticed i was missing always 5 messages in a row, then was receiving fine for 3 message in a row etc…  
so by looking at frequencies, i noticed that it always work when received on those freqs:

> 868100000  
> 868300000  
> 868500000

and always fails from those freqs

> 867100000  
> 867300000  
> 867500000  
> 867700000  
> 867900000

I’m running out of idea and will probably migrate everything back to ttn v2 if not, but im asking if maybe anyone of you have any clue where to start searching ?

Thanks a lot 🙂

EDIT:

- on my location, im the only gateway and thus my end user node report only to my gateway
- i also deleted all my enduser node from ttn v2 console

---

<div class="post-metadata">

**Author:** ![Raccoon](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/raccoon/32/35697_2.png) [@Raccoon](https://www.thethingsnetwork.org/forum/u/Raccoon)\
**Post date:** [May 11, 2021, 6:54pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/2 "2021-05-11T18:54:00Z")

</div>

Adding logs from my webhook integrations

> 2021-05-11 15:57:47,549 - INFO - main - NodeName: node-01 - count: 24 - freq: 868100000  
> 2021-05-11 16:07:55,107 - INFO - main - NodeName: node-01 - count: 25 - freq: 868300000  
> 2021-05-11 16:18:01,088 - INFO - main - NodeName: node-01 - count: 26 - freq: 868500000  
> 2021-05-11 17:18:39,857 - INFO - main - NodeName: node-01 - count: 32 - freq: 868100000  
> 2021-05-11 17:28:47,717 - INFO - main - NodeName: node-01 - count: 33 - freq: 868300000  
> 2021-05-11 17:38:52,938 - INFO - main - NodeName: node-01 - count: 34 - freq: 868500000  
> 2021-05-11 18:39:32,522 - INFO - main - NodeName: node-01 - count: 40 - freq: 868100000

We can clearly see that from count **26** to **32** , it miss 5 messages, corresponding to the 5 frequency that always fails, again it happen from **34** to **40**.

The very same happen to all my other nodes:

i receive ok first message at 868100000  
i receive ok 2nd message at 868200000  
i receive ok 3rd message at 868300000  
i get device not found for the 4th message at 867100000  
i get device not found for the 5th message at 867300000  
i get device not found for the 6th message at 867500000  
i get device not found for the 7th message at 867700000  
i get device not found for the 8th message at 867900000  
and again…  
i receive ok the 9th message at 868100000  
i receive ok the 10th message at 868200000

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [May 11, 2021, 7:51pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/3 "2021-05-11T19:51:04Z")

</div>

For ABP devices you need to tell the V3 stack which frequencies have been preprogrammed into the node apart from the 3 mandatory frequencies.  
The dialog for this can be found in the advances network properties. You will need to reset the frame counter for the new settings to become active. Search the forum for instructions on how to do this with V3,

![image](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/d/b/dbba010759bb60661dddba9826c10820a4ee7b5b.jpeg)

---

<div class="post-metadata">

**Author:** ![Raccoon](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/raccoon/32/35697_2.png) [@Raccoon](https://www.thethingsnetwork.org/forum/u/Raccoon)\
**Post date:** [May 11, 2021, 8:15pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/4 "2021-05-11T20:15:24Z")

</div>

Thanks a lot for your response 😉  
Nevertheless, i already did that as it was part of the tutorial mentioned above.  
Here is my console :  
 ![Screenshot 2021-05-11 at 22.13.10](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/f/0/f0a5ed7af5081aa97d4e54158321e1af0a80dfd4.png)

i also did reset the frame counter ( i mean i just checked the checbox reset frame counter), it started counting at 0 again then i unchecked it , or maybe you mean running this command instead ? :  
`ttn-lw-cli end-devices set [application-id] [device-id] --session.last-a-f-cnt-down 0`

I added those frequencies after having set up the node config though, should i recreate the whole node config and add them during first time configuration ? Does the order also matter ? meaning from lower to higher ?

Thanks a lot 🙂

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [May 11, 2021, 8:45pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/5 "2021-05-11T20:45:55Z")

</div>

The order is not important, however the V3 stack needs to be forced in starting a new session. The easiest solution would be to add the device again with the addition frequencies. There should be other ways which may find on the forum, O recall having seen messages on the subject.

---

<div class="post-metadata">

**Author:** ![Raccoon](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/raccoon/32/35697_2.png) [@Raccoon](https://www.thethingsnetwork.org/forum/u/Raccoon)\
**Post date:** [May 11, 2021, 8:47pm UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/6 "2021-05-11T20:47:00Z")

</div>

Thanks a lot , as its getting late in europe, i will try your suggestion tomorrow 😉  
Thanks again a lot for your help 😉

---

<div class="post-metadata">

**Author:** ![Raccoon](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/raccoon/32/35697_2.png) [@Raccoon](https://www.thethingsnetwork.org/forum/u/Raccoon)\
**Post date:** [May 12, 2021, 10:59am UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/7 "2021-05-12T10:59:24Z")

</div>

Alright, so reset the frame counter and making a hard reset on the node worked, now all my node report every 10 min just like old good v2 times. Migration to v3 100% complete. AwEsOmE !!!

Thanks a ton for your help 😉

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [May 13, 2021, 10:59am UTC](https://www.thethingsnetwork.org/forum/t/solved-migration-from-v2-to-v3-give-device-not-found-depending-on-frequency/47604/8 "2021-05-13T10:59:55Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.
