[ST OMU] Example to create a logfile template to monitor two logfiles in a Windows node

PROBLEM:
How to create a template that would monitor both logfiles (two drives; C and E); on a windows agent?

The two logfiles are
C:\DIR\file1.log

E:\DIR\file2.log




SOLUTION:
The following command works fine to monitor two log files located on different drives location:
<`cmd /c “dir /s /b c:\temp\file1.log e:\temp\file2.log 2>NUL & exit 0”`>



An example template would have the following attributes:

LOGFILE "TwoLog"
        DESCRIPTION "TwoLog"
        LOGPATH "<`cmd /c “dir /s /b c:\temp\file1.log e:\temp\file2.log 2>NUL & exit 0”`>"
        INTERVAL "1m"
        CHSET ASCII
        MSGCONDITIONS
                DESCRIPTION "match all"
                CONDITION
                        TEXT "<*.match>"
                SET
                        TEXT "logfile match: <match>"

The important line is:

<`cmd /c “dir /s /b c:\temp\file1.log e:\temp\file2.log 2>NUL & exit 0”`>


This is documented in the following KCS document: http://support.openview.hp.com/selfsolve/document/KM00943518