Which works; so I thought I’d automate it in cron (every hour or so) to make sure I’m never without connectivity too long.
However, it does not work from cron. I presumed it was a path/env variable that was the issue so I created a shell script (which works) and called that from cron (which didn’t work).
shall we have a look into and check why it does not work from cron and try to find a solution ?
Background just in case that you are not aware of it: not all environment settings like PATH are the same as in your users account.
It could be that just a few envonrment variables are missing.
Hi,
this is correct and normal, expected behavior of cron.
There is one typo in the list of environment variables - the O for OPENHAB_RUNTIME is missing.
I had two issues causing the HomeKit connection to be lost.
The Raspberry PI was running slowly. I haven’t 100% confirmed this, but from observation it appears the connection was timing out. I fixed this with zram config.
The firewall was blocking avahi ports. The firewall allowed the initial connection (to the homekit binding) but it would block some mdns. Opening the ports fixed this.