0

I add one line to /etc/rc.local:

sudo python /home/pi/web/xxx.py

then restart the system. Unfortunately, I am never able to ping successfully the device! Moreover, I could not ssh to the device to see any log on the system...

Anyone help me?

2
  • Then plug a screen into it and see what it's doing... Commented Dec 1, 2015 at 2:41
  • First do @TessellatingHeckler suggested.Then remove sudo from the line . Then could you try once ?
    – Punit Vara
    Commented Dec 1, 2015 at 3:19

1 Answer 1

1

From another Linux pc try to mount your SD and edit the /etc/rc.local.

If the other pc doesn't have a SD slot, use a universal memory reader.

Take into account that the /etc/rc.local must exit with the status error 0. And maybe your python script is failing and exiting with a different status error value.

By the way, your /home/pi/web/xxx.py script should be exacuted by the pi user, so your /etc/rc.local should have some like this:

sudo -u pi python /home/pi/web/xxx.py

exit 0

I hope it helps you.

Regards!

1
  • Thanks! By mounting SD card to another linux machine, I removed the line I added. Now the system boots successfully!
    – qingjinlyc
    Commented Dec 1, 2015 at 8:03

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.