1

I have tried doing in rc.local , bashrc file but rc.local not showing any log or not clear if it is running. bashrc is making the script run only when i open the terminal. I need to run without user intervention and my script involves network connection and websocket communication. So running in startup will ensure i get network? Thank you in advance.

3
  • you could make a daemon and start it after network is established Commented Jan 29, 2021 at 7:55
  • i am very new to Linux environment also , can you share an example or refer me any link to follow Commented Jan 29, 2021 at 9:56
  • Here are 5 Ways, number 4 is the daemon way: dexterindustries.com/howto/… Commented Jan 30, 2021 at 13:10

1 Answer 1

1

you can connect a LED to your raspberry pi to check weather your code is running or not

/home/pi/bashrc.
sudo python3 #LED file 
sudo python3 #your file name

this should make your code run every time the power is on its not depend that you open the terminal or not

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

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.