Gateway bridge subscribing topic

Hi

Should the gateway bridge be subscribed to all gateways ?
Asking because I have several gateways connected. On one device specific, Class C, the downlink keep scheduled.
On NS logs I have

12/28/2021 1:57:00 PMINFO[0277] gateway/mqtt: publishing gateway command      command=down downlink_id=dbe76e32-657e-429a-bede-1a37d88c279f gateway_id=0000f80332020e73 qos=1 topic=gateway/0000f80332020e73/command/down
12/28/2021 1:57:00 PMINFO[0277] device-session saved                          ctx_id=dbe76e32-657e-429a-bede-1a37d88c279f dev_addr=00022259 dev_eui=f803320100022259
12/28/2021 1:57:00 PMINFO[0277] storage: downlink-frame saved                 ctx_id=dbe76e32-657e-429a-bede-1a37d88c279f token=56295
12/28/2021 1:57:00 PMINFO[0277] device-queue item updated                     ctx_id=dbe76e32-657e-429a-bede-1a37d88c279f dev_eui=f803320100022259 emit_at_time_since_gps_epoch="<nil>" f_cnt=0 is_pending=false timeout_after="<nil>"
12/28/2021 1:57:02 PMINFO[0279] gateway/mqtt: publishing gateway command      command=down downlink_id=290f9596-2e18-4226-931b-05ae60d254e5 gateway_id=0000f80332020e73 qos=1 topic=gateway/0000f80332020e73/command/down
12/28/2021 1:57:02 PMINFO[0279] device-session saved                          ctx_id=290f9596-2e18-4226-931b-05ae60d254e5 dev_addr=00022259 dev_eui=f803320100022259
12/28/2021 1:57:02 PMINFO[0279] storage: downlink-frame saved                 ctx_id=290f9596-2e18-4226-931b-05ae60d254e5 token=10511
12/28/2021 1:57:02 PMINFO[0279] device-queue item updated                     ctx_id=290f9596-2e18-4226-931b-05ae60d254e5 dev_eui=f803320100022259 emit_at_time_since_gps_epoch="<nil>" f_cnt=0 is_pending=false timeout_after="<nil>"
12/28/2021 1:57:04 PMINFO[0281] gateway/mqtt: publishing gateway command      command=down downlink_id=0ba1c2ae-af7e-478c-bde1-6dda70d911db gateway_id=0000f80332020e73 qos=1 topic=gateway/0000f80332020e73/command/down
12/28/2021 1:57:04 PMINFO[0281] device-session saved                          ctx_id=0ba1c2ae-af7e-478c-bde1-6dda70d911db dev_addr=00022259 dev_eui=f803320100022259
12/28/2021 1:57:04 PMINFO[0281] storage: downlink-frame saved                 ctx_id=0ba1c2ae-af7e-478c-bde1-6dda70d911db token=2977
12/28/2021 1:57:04 PMINFO[0281] device-queue item updated                     ctx_id=0ba1c2ae-af7e-478c-bde1-6dda70d911db dev_eui=f803320100022259 emit_at_time_since_gps_epoch="<nil>" f_cnt=0 is_pending=false timeout_after="<nil>"
12/28/2021 1:57:06 PMINFO[0283] gateway/mqtt: publishing gateway command      command=down downlink_id=c62f0914-276b-4739-a0ca-909f519385c0 gateway_id=0000f80332020e73 qos=1 topic=gateway/0000f80332020e73/command/down
12/28/2021 1:57:06 PMINFO[0283] device-session saved                          ctx_id=c62f0914-276b-4739-a0ca-909f519385c0 dev_addr=00022259 dev_eui=f803320100022259
12/28/2021 1:57:06 PMINFO[0283] storage: downlink-frame saved                 ctx_id=c62f0914-276b-4739-a0ca-909f519385c0 token=50735
12/28/2021 1:57:06 PMINFO[0283] device-queue item updated                     ctx_id=c62f0914-276b-4739-a0ca-909f519385c0 dev_eui=f803320100022259 emit_at_time_since_gps_epoch="<nil>" f_cnt=0 is_pending=false timeout_after="<nil>"
12/28/2021 1:57:06 PMINFO[0283] gateway/mqtt: uplink frame received           gateway_id=0000f80332020e73 uplink_id=8cc7b7c4-69e8-4f3f-bff0-71197eb98c7e
12/28/2021 1:57:07 PMINFO[0284] uplink: frame(s) collected                    ctx_id=e75a1881-4c6b-4de3-8285-13fb4471be30 mtype=UnconfirmedDataUp uplink_ids="[8cc7b7c4-69e8-4f3f-bff0-71197eb98c7e]"

Like the NS trying to send it and never getting the confirmation from gateway bridge.

I’m using semtech udp pkt fwd.
On GWB logs, I can’t see this gateway (0000f80332020e73) subscribing, however, I can see others.
This gateway is reporting a lot of uplinks, as it should be, so doesn’t looks like is a network error.

Here is my GWB once I restart it:

12/28/2021 2:01:14 PMINFO[0512] signal received                               signal=terminated
12/28/2021 2:01:14 PMWARN[0512] shutting down server
12/28/2021 2:01:14 PMINFO[0512] integration/mqtt: publishing state            gateway_id=fd9e531b6493c7bb qos=1 state=conn topic=gateway/fd9e531b6493c7bb/state/conn
12/28/2021 2:01:16 PMINFO[0000] backend/semtechudp: starting gateway udp listener  addr="0.0.0.0:1700"
12/28/2021 2:01:16 PMWARN[0000] [store]    memorystore wiped                  module=mqtt
12/28/2021 2:01:16 PMINFO[0000] integration/mqtt: connected to mqtt broker
12/28/2021 2:01:16 PMINFO[0000] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=1e253143-7f27-451f-83ae-0c42f4355ed4
12/28/2021 2:01:19 PMINFO[0003] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=ac4ea783-c29b-49f9-9f9d-a7826505c0d7
12/28/2021 2:01:21 PMINFO[0005] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=94fa9c11-c396-465c-88b8-ca23560f8ba2
12/28/2021 2:01:22 PMINFO[0006] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=951a09ad-6876-4e7e-83c5-14249edcaa8e
12/28/2021 2:01:22 PMINFO[0006] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=4548bfab-3db1-48db-bc0a-841c1358a30b
12/28/2021 2:01:24 PMINFO[0007] integration/mqtt: publishing event            event=up qos=1 topic=gateway/0000f80332020e73/event/up uplink_id=0ea47f58-50e6-4d93-b8d2-db9d460c8e14
12/28/2021 2:01:25 PMINFO[0009] integration/mqtt: subscribing to topic        qos=1 topic="gateway/fd9e531b6493c7bb/command/#"
12/28/2021 2:01:25 PMINFO[0009] integration/mqtt: publishing state            gateway_id=fd9e531b6493c7bb qos=1 state=conn topic=gateway/fd9e531b6493c7bb/state/conn

Any help ?

Thanks

are you deploying the gwb directly on the gateway, so one gateway equals one gwb or do you have a service for all?

It is a central server for all gateways

Restarting the gateway did the trick. Just can’t understand yet why

if it’s a central, the gwb holds an in-memory table of the gateways it has received a payload from (stats, uplinks…) then when the NS sends a message to a gateway, it does so by sending a message to the topic, that’s why the gwb is then subscribed to all of them.

UDP has rather short “timings” on the middle-boxes in the path to your gateways (more so if you are on a mobile-phone network), maybe lowering the stats message could help with that gateway, sometimes is just a bug in the pkt-fwd and it blocks.

1 Like