Dragino PG1301 on RPI 4 (Raspi OS 12) - lorapktfwd.service: Failed to execute /usr/bin/lora_pkt_fwd

Hi there,
I wanted to upgrade my multi-purpose RasPi 3B to a RasPi 4 due to RAM constraints.
I use the Dragino PG1301 as a gateway and just followed the instructions (https://www.dragino.com/downloads/downloads/LoRa_Gateway/PG1301/PG1301_UserManual_v1.0.6.pdf).
When I check the status of the service, I get:
Process: 1402 ExecStartPre=/usr/bin/reset_lgw.sh start (code=exited, status=0/SUCCESS)
Process: 1415 ExecStart=/usr/bin/lora_pkt_fwd (code=exited, status=203/EXEC)
Process: 1416 ExecStopPost=/usr/bin/reset_lgw.sh stop (code=exited, status=0/SUCCESS)

When I check the logs using “sudo journalctl -u lorapktfwd -f”:
lorapktfwd.service: Failed to execute /usr/bin/lora_pkt_fwd: No such file or directory

But the file is there, so I tried to edit the permissions using “sudo chmod +x /usr/bin/lora_pkt_fwd”, which didn’t help either.

Any ideas are appreciated :slight_smile:
Thanks,
Benjamin

Try running ‘file /usr/bin/lora_pkt_fwd’ and post the output…

/usr/bin/lora_pkt_fwd: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, BuildID[sha1]=eeb91a5f893755b9d0796e5ab1e70adebf5d1bdd, not stripped

Are you using the 32 bit version of the Raspberry OS on your system?

No, 64-bit…

Based on the direction you went to, I have installed a 32-bit Raspi OS on my machine, now it is working.
But do you have suggestions what to do if I want to keep the 64-bit OS?

Two options:

  • compile the packet forwarder as 64 bit application
  • use the 32 bit binary with the required shared libraries it depends on (ldd should list them)

Got it running now on a 64-bit RaspiOS. Actually, I was already pretty close to the resolution as in the instructions, Dragino also shows how to compile the pkt-fwd. Unfortunately, the repo is not only anymore, so I didn’t go this route as this meant, I need to use some other forwarder.
Now I did it using fhessel/dragino_pi_gateway_fwd. Compiling it on a 64-bit system will also produces the app in 64-bit.
Thanks for pushing me into the right direction!

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