multitech-installer icon indicating copy to clipboard operation
multitech-installer copied to clipboard

mp_pkt_fwd fails to exit on stop

Open Eelviny opened this issue 6 years ago • 3 comments

When executing /etc/init.d/ttn-pkt-forwarder stop, the process /opt/lora/mp_pkt_fwd usually does not also get stopped.

This breaks functionality with packages like monit, which attempt to restart the service when an issue is detected. Instead, a duplicate process is spawned, and the problem continues.

I fixed this issue by modifying the /etc/init.d/ttn-pkt-forwarder file, so that do_stop() does killall mp_pkt_fwd. The original behaviour is killall -1 mp_pkt_fwd. This is a "quick fix" but the issue lies in mp_pkt_fwd refusing to exit cleanly.

Eelviny avatar Jan 22 '19 15:01 Eelviny

This is on an MTCAP-LEU1-868 running mLinux 4.0.1.

Eelviny avatar Jan 22 '19 15:01 Eelviny

I might be wrong about this - more info on how this actually works is appreciated

Eelviny avatar Jan 28 '19 11:01 Eelviny

To fix this, replace the '-s 1' with '-s 3' and 'killall -1' with 'killall -3' in /etc/init.d/ttn-pkt-forwarder

kersing avatar Feb 11 '19 22:02 kersing