Version 2

    This template searches through the last modified file in a specified folder and returns the line number and column of the first occurrence of a specified search text. The last modified file is filtered by the filename substring. This is helpful for log files that keep rotating and when there is a need to search in the latest log file.

    Prerequisites: WMI access to the target server.

    Credentials: Windows Administrator on the target server.

    Note: Tested on Windows Server 2008 R2

    Monitored Components:

    This component looks through all the files in a folder, filters for files based on the substring specified and finds the last modified file. It tries to search for the text specified in this file. If the search string is found it returns the line and column number where it is found, if not returns message appropriately.

    Arguments: Folder to scan, filename pattern, search string to find

    The template can be enhanced to include regular expression searches and global searches. The template view can also be customized to display parts of the log file that is being searched.