36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
-
+
|
<tr><td>WARNING</td> <td>2</td></tr>
<tr><td>CHECK</td> <td>3</td></tr>
</table>
<h3>[Installation]</h3>
<h3>Command file details</h3>
Your command file is written in scheme but don't let that scare you. Only a handful of single line stanzas are needed to write a rock solid log analyzer. Here is an [example command file] and the [logpro output] from running against this [example log file]
Your command file is written in scheme but don't let that scare you. Only a handful of single line rules are needed to write a rock solid log analyzer. Here is an [example command file] and the [logpro output] from running against this [example log file]
More examples can be seen in the example.logpro file in the source directory [http://www.kiatoa.com/fossils/logpro/doc/tip/example.logpro]
<h3>Syntax</h3>
Triggers:
<verbatim>
|
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
|
-
+
+
|
( section "section name" "start trigger" "end trigger" )
</verbatim>
# The "section name" is a string.
# The "start trigger" and "end trigger" are strings that match the name of a trigger
Expect rules:
<verbatim>
( expect [in|not-in] "section name" [> or < or =] integer #/regular expression/ )
( expect:required [in|not-in] "section name" [> or < or =] integer #/regular expression/ )
</verbatim>
# Types of expect include: expect:required, expect:ignore, expect:warn, expect:error and expect:waive
<h3>Sections</h3>
You can break your log file into sections to make applying the rules very specific. For example you may want to only apply a set of rules in the compile section of the log file related to compiler failures.
Example: Create a section called "Init" that only applies between a line containing the string "This is a header" and a blank line. The lines match on regular expressions delimited by #/ and /.
<verbatim>
|