1

If I change my config to autologin to the CLI using raspi-config I get an error at the end of the boot sequence:

~$ python3: can't open file 'home/pi/path_to_old_script/script.py

I have checked:

  1. /home/pi/.config/lxsession/LXDE-pi/autostart
  2. /etc/rc.local
  3. crontab -e

It does not seem to occur when I boot to the GUI/Desktop.

I am not sure where this is being called from.

Is there anywhere else I could have added it that I have forgotten that would cause it to run at startup?

Any advice would be appreciated.

3
  • 1
    Don’t put GUI scripts in rc.local (indeed don’t put anything)
    – Milliways
    Commented Apr 29, 2019 at 12:18
  • 1
    What's the question? How to avoid the error message? How to make the script running?
    – Ingo
    Commented Apr 29, 2019 at 12:40
  • I edited my initial post, but I am not sure where this is being called from. Is there anywhere else I could have added it that I have forgotten that would cause it to run at startup? Commented Apr 29, 2019 at 12:53

1 Answer 1

1

There are other places to check for startup scripts on Raspbian (assuming that is what you are using), one of them being SystemD. If you type systemctl it will list things configured for systemd. There may also be files in the older /etc/init.d folder, although these are no longer used in recent Raspbian versions.

Other places scripts can be started are a .bashrc, situated in the home directory of a user, which would run every time a new bash prompt is started and /etc/profile which is also run every time a new bash session is created.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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