II've tried to install the presence_detection_domoticz_fritzbox.sh from funky, but i can't get it worked...
- As described in the procedure the install done at the Raspberry.
- Start the script, it asks the Fritzbox IP, the Repeater IP, password and the devices to monitor.
- The hardware is created in domoticz.
- In the devices screen the devices appear, wich i've moved to my Switches screen (Green arrow)
- After that change the CRON job file with crontab -e and paste the line witch given by ending the script.
If i test with sudo bash presence_detection.sh debug, i'll see the script is working, the Fritz router gives the information for the devices the Domoticz settings chaged to the actual Fritzbox status, so far it works but it does not update automatically...
so i'll checked the CRON job,
first ps -eaf | grep cron
Output > root 1369 1 0 00:36 ? 00:00:01 /usr/sbin/cron -f
pi 14901 14877 0 14:07 pts/0 00:00:00 grep --color=auto cron
Ok, (Or not ?)
After that tail /var/log/auth.log
Output >
Jan 5 14:07:23 raspberrypi sshd[14862]: pam_unix(sshd:session): session opened for user pi by (uid=0)
Jan 5 14:07:23 raspberrypi systemd-logind[298]: New session c6 of user pi.
Jan 5 14:08:01 raspberrypi CRON[14911]: pam_unix(cron:session): session opened for user pi by (uid=0)
Jan 5 14:08:01 raspberrypi CRON[14912]: pam_unix(cron:session): session opened for user root by (uid=0)
Jan 5 14:08:01 raspberrypi CRON[14912]: pam_unix(cron:session): session closed for user root
Jan 5 14:08:01 raspberrypi CRON[14911]: pam_unix(cron:session): session closed for user pi
Jan 5 14:09:01 raspberrypi CRON[14981]: pam_unix(cron:session): session opened for user pi by (uid=0)
Jan 5 14:09:01 raspberrypi CRON[14982]: pam_unix(cron:session): session opened for user root by (uid=0)
Jan 5 14:09:01 raspberrypi CRON[14981]: pam_unix(cron:session): session closed for user pi
Jan 5 14:09:01 raspberrypi CRON[14982]: pam_unix(cron:session): session closed for user root
Seems to be fine (or it's a little bit to fast ?)
and then tail /var/log/auth.log
Output >
Jan 5 14:07:23 raspberrypi sshd[14862]: pam_unix(sshd:session): session opened for user pi by (uid=0)
Jan 5 14:07:23 raspberrypi systemd-logind[298]: New session c6 of user pi.
Jan 5 14:08:01 raspberrypi CRON[14911]: pam_unix(cron:session): session opened for user pi by (uid=0)
Jan 5 14:08:01 raspberrypi CRON[14912]: pam_unix(cron:session): session opened for user root by (uid=0)
Jan 5 14:08:01 raspberrypi CRON[14912]: pam_unix(cron:session): session closed for user root
Jan 5 14:08:01 raspberrypi CRON[14911]: pam_unix(cron:session): session closed for user pi
Jan 5 14:09:01 raspberrypi CRON[14981]: pam_unix(cron:session): session opened for user pi by (uid=0)
Jan 5 14:09:01 raspberrypi CRON[14982]: pam_unix(cron:session): session opened for user root by (uid=0)
Jan 5 14:09:01 raspberrypi CRON[14981]: pam_unix(cron:session): session closed for user pi
Jan 5 14:09:01 raspberrypi CRON[14982]: pam_unix(cron:session): session closed for user root
pi@raspberrypi:~ $ tail /var/log/syslog
Jan 5 14:08:01 raspberrypi CRON[14912]: (CRON) info (No MTA installed, discarding output)
Jan 5 14:08:01 raspberrypi CRON[14911]: (CRON) info (No MTA installed, discarding output)
Jan 5 14:09:01 raspberrypi CRON[14990]: (pi) CMD (/home/pi/presence_detection_domoticz_fritzbox/presence_detection.sh >> /home/pilogs/presence2.log)
Jan 5 14:09:01 raspberrypi CRON[14981]: (CRON) info (No MTA installed, discarding output)
Jan 5 14:09:01 raspberrypi CRON[14991]: (root) CMD (/home/pi/presence_detection_domoticz_fritzbox/presence_detection.sh)
Jan 5 14:09:01 raspberrypi CRON[14982]: (CRON) info (No MTA installed, discarding output)
Jan 5 14:10:01 raspberrypi CRON[15044]: (root) CMD (/home/pi/presence_detection_domoticz_fritzbox/presence_detection.sh)
Jan 5 14:10:01 raspberrypi CRON[15045]: (pi) CMD (/home/pi/presence_detection_domoticz_fritzbox/presence_detection.sh >> /home/pilogs/presence2.log)
Jan 5 14:10:01 raspberrypi CRON[15036]: (CRON) info (No MTA installed, discarding output)
Jan 5 14:10:01 raspberrypi CRON[15037]: (CRON) info (No MTA installed, discarding output)
Ok, no MTA that's correct but the command is executed every minute ....
But there is also no log created at /home/pilogs/presence2.log

I think the CRONjob does nothing what i'm doing wrong ?
What to do now ?
Hopely someone can help me with the solving this problem
Thanks a lot in advantage
Rob (Team Kleijn)