I've several Rasberry Pi with an app written in QT that automatically start at logon... the automatic start is made through the /home/pi/.config/lxsession/LXDE-pi/autostart file. I've inserted in this file a rung "@bash /home/pi/Desktop/delayed_autostart &" to launch another file with a delayed start because I've to wait that the wifi connects to the router. the other file contains: sleep 20 /home/pi/Desktop/MYAPP

all works ok (the app is launched after 20 seconds) but........ when I need to upgrade the app I connect through VNC to the raspberry to kill the app (I open the task manager ad I kill MYAPP), I copy through SSHFTP the new app, but after 20 seconds again the app is relaunched! (°_°) so I've two identical task running... and if i kill it again is relaunched for 3 or 4 times, then stops to be relaunched... Do you know why?


Try killing it by process name; use the below command:

 pkill -9 processname
  • same problem also killing with pkill – Andrea Feb 13 at 9:25
  • solved. the problem was that the delayed bash script remained opened in background, so starts the app over and over... modified killing bash adding after sleep 20 /home/pi/Desktop/MYAPP pkill bash – Andrea Feb 13 at 9:48

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.