I wonder if I can write a script that will monitor for a change in a file and execute some action when the change is detected.
Detailed explanation:
- OpenVPN writes its status to a file every 1 minute.
- I need to parse this status file and take action.
- OpenVPN truncates the status file before writing to it.
- I tried writing to a named pipe, but I get undesirable (but not fatal) errors in the app when it fails to truncate the pipe.