Hi mates, we all know how uncomfortable are unexpected "hangs" of our system.. sometime even critical, and how hard is to guess what can be wrong there.. as they may happen really seldom, almost impossible to replicate, very difficult to dignostic.
In past I had power troubles with my RaspberryPI3, now I solved them but I had once again an hang, maybe caused from my "not best quality" SD, maybe not, cause it affected the TCP stack.. and how TCP can be connected to SD (while other services like NR, I2C bus, ICMP ping, reep working regulary) I really don't understand.
To avoid any possible problems we need a watchdog, I mean a real watchdog that is able to reboot PI and solve the problem, eventually let us know that it happen wo be warned, I see it the only way to be sure it will work anycase.
There are different ways to obtain that, someone will suggest to interrupt the power supply somehow, maybe with external Arduino, others may suggest to use internet services that allert if the "ping" to PI will stop. I'm not intersted on these solutions, I would like to use the internal hardware watchdog of PI that should be activated turning on its service, and managed properly.
Hardware watchdog is present in every microcontroller/automation system and it can trig an hardware reboot, it should be present in every automation system, for this reason I'm suggesting NR developers to consider this too, in my opinion it's important.
Features needed:
PI should always be reachabel by SSH, so we need to check the port 22 if responsive on loopback.
Web NR management port 1080 is good to check too, as the NR is responsive
A module on NR where we can set the ports to be checked and accept incoming messages to check NR is working properly is welcome, if no message is incoming after certain time the watchdog is triggered.
ABout the watchdog services there is docmentation around, but hard for me to understand how to work with it properly, Domoticz did somenthng to manage it, maybe it chcks already ports too, it can be worth to have a look on it..
I asked their help but received none ((
https://www.domoticz.com/wiki/Setting_up_the_raspberry_pi_watchdog