You guys are right. So let me be a little more specific.
My raspberry runs in a so called "headles mode". It is located in an electrical cabinet in my cellar. I get access to this device over ssh.
The task this raspberry has to fulfill is twofold.
First: monitor the state of an electrical switch
Second: at status change post a IFTTT trigger with some jason attached.
So for about three years my raspberry did the job aside from a needed reboot, lets say two times a year, because the programm or something else stopped working. But after the reboot the raspi was up and running again.
To get the job done I worte a little pyton program, starting with the shebang
I made the programm executable with
Code: Select all
sudo chmod +x /usr/local/bin/person_enter_leave_v6.py
and edited the rc.local with
and added the line
python /usr/local/bin/person_enter_leave_v6.py &
just before
So far so good...
now, when I check, after a reboot, if the programm is actually executed with
the result is
root 418 1 0 Dec28 ? 00:00:05 python /usr/local/bin/person_enter_leave_v6.py
pi 17927 17857 0 08:35 pts/0 00:00:00 grep --color=auto python
so I be very positive it is loaded
But unfortunately since last saturday the programm won't post the IFTTT trigger, perhaps it don't check the electrcal switch either, or both, or vice versa.
I can start the programm manually with
Code: Select all
python /usr/local/bin/person_enter_leave_v6.py
but this is no solution, because as soon as I exit the ssh terminal, the program is ended to.
So, now I hope that clears things up and someone come up with some advice for this problem.
Regards Patrick