All questions related to installations, configurations and maintenance of Advanced Host Monitor (including additional tools such as RMA for Windows, RMA Manager, Web Servie, RCC).
I am using HM 6.54. We are running RMAs on a couple hundred computers and have the requirement for HM to carry out an action once a file stops growing in size. For example this could be a .avi file that is being written by another program. The file will be continually written for an unknown period of time, and when it is finished the file will no longer be written to again.
Can we get HM to alert us, telling us that the file or a file in that directory has been written and is now a complete file?
I apologise if this is an easy thing to do, I couldn't figure it out and didn't see it in the forums. Any help gratefully appreciated.
I think, you may try "Folder/File Availability" test method with "Alert when file exists and older than N min" option. So, HostMonitor will alert you when file is not appended for N minutes.
Warning - the test "Alert when file exists and older than N min" will not tell you if the file is growing in size.
It would be easy to assume if the file is not older than N min that it is being appended, but it is possible that your application opens the file, fails to post changes and closes the file - changing the file date with no apparent change in it's contents.
I haven't looked closely at this but it might be possible to use the "Folder/File Size test" and compare current results with the previous results using the available Reply macro variables.
Another potential solution - use the "File Integrity" test and choose to "Reverse the alert". When the CRC test fails to fail the file is complete. The only problem is that this requires that you know the file name, since it is specified in the test parameters. If that's a constant, then no problem. You might even be able to accommodate a sequential file naming system with some effort, though I haven't looked very deeply at that either.
Another note: Depending upon the file type being written you might also need to check the contents of the file in order to see if there is a necessary opening 'header' or closing 'footer' to the file. Otherwise you have a corrupt or incomplete file, which you might wish to alarm on as well. That might require some programming.
Anybody else got any ideas on tackling that one?