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.

asked Apr 29, 2019 at 11:46
3
  • 1
    Don’t put GUI scripts in rc.local (indeed don’t put anything) Commented Apr 29, 2019 at 12:18
  • 1
    What's the question? How to avoid the error message? How to make the script running? 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.

answered Apr 29, 2019 at 13:37
0

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.