I need to make sure that a chosen process is not hanged. I thought I'd program this process to write to some /proc file that will be periodically monitored by some other process/module. If there is no change in the file for some time the application would be considered hanged. Just as a watchdog in uC.
However I don't know if this is the best approach. As I'm not really much into deep Linux engineering I thought it is better to ask which way is the easiest before starting to learn writing modules, /proc filesystem, etc. Ha!
I've found some information on Monit (https://mmonit.com/monit/). Maybe this would be better?
What would you recommend to be the best way to implement the "watchdog" functionality here?
Thanks a lot!
Paweł