How can I check a file content?
Some examples of custom monitors are delivered with IPHost Network Monitor installation. One of them is a script that checks the content of a file (and extracts specified value from the file). This VBScript (file_content.vbs) can be used to find specific content in a given file. To use it, locate iphost_file_content.vbs file in scripts folder of IPHost Monitor installation, use 'Run Script'program type and 'Standard' Program Mode. The parameters expected are:
filename mode string credentials
Where 'filename' is the file name, 'mode' is either 'C' (count - find the number of occurrences of 'string') or 'F' (find the first numeric string after the first 'string' is found); credentials, if present, are of the same format as provided for '-l' parameter for dirsize_kb sample program shipped with IPHost Network Monitor.
An example of command line is
"C:\ProgramData\IPHost Network Monitor\logs\error.log" C shutdown
(i.e., scan the IPHost Monitor error log file and return the number of 'shutdown' strings found)




