CheckLogFile
CheckLogFile
— CheckLogFile¶File for checking log files and various other forms of updating text files
Queries (Overview):
A list of all available queries (check commands)
Command | Description |
---|---|
check_logfile |
Check for errors in log file or generic pattern matching in text files. |
Aliases (Overview):
A list of all short hand aliases for queries (check commands)
Command | Description |
---|---|
checklogfile | Alias for: check_logfile |
Commands (Overview):
TODO: Add a list of all external commands (this is not check commands)
Configuration (Overview):
Common Keys:
Path / Section | Key | Description |
---|---|---|
/settings/logfile/real-time |
enabled |
REAL TIME CHECKING |
A quick reference for all available queries (check commands) in the CheckLogFile module.
check_logfile
¶CheckLogFile
check_logfile
Usage:
Option | Default Value | Description |
---|---|---|
filter |
Filter which marks interesting items. | |
warning |
Filter which marks items which generates a warning state. | |
warn |
Short alias for warning | |
critical |
Filter which marks items which generates a critical state. | |
crit |
Short alias for critical. | |
ok |
Filter which marks items which generates an ok state. | |
debug |
N/A | Show debugging information in the log |
show-all |
N/A | Show details for all matches regardless of status (normally details are only showed for warnings and criticals). |
empty-state |
ignored | Return status to use when nothing matched filter. |
perf-config |
Performance data generation configuration | |
escape-html |
N/A | Escape any < and > characters to prevent HTML encoding |
help |
N/A | Show help screen (this screen) |
help-pb |
N/A | Show help screen as a protocol buffer payload |
show-default |
N/A | Show default values for a given command |
help-short |
N/A | Show help screen (short format). |
top-syntax |
${count}/${total} (${problem_list}) | Top level syntax. |
ok-syntax |
ok syntax. | |
empty-syntax |
%(status): Nothing found | Empty syntax. |
detail-syntax |
${column1} | Detail level syntax. |
perf-syntax |
${column1} | Performance alias syntax. |
line-split |
n | Character string used to split a file into several lines (default n) |
column-split |
t | Character string to split a line into several columns (default t) |
split |
Alias for split-column | |
file |
File to read (can be specified multiple times to check multiple files. | |
files |
A comma separated list of files to scan (same as file except a list) |
filter
(CheckLogFile, check_logfile)¶count total ok_count warn_count crit_count problem_count list ok_list warn_list crit_list problem_list detail_list status column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
warning
(CheckLogFile, check_logfile)¶count total ok_count warn_count crit_count problem_count list ok_list warn_list crit_list problem_list detail_list status column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
warn
(CheckLogFile, check_logfile)¶critical
(CheckLogFile, check_logfile)¶count total ok_count warn_count crit_count problem_count list ok_list warn_list crit_list problem_list detail_list status column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
crit
(CheckLogFile, check_logfile)¶ok
(CheckLogFile, check_logfile)¶count total ok_count warn_count crit_count problem_count list ok_list warn_list crit_list problem_list detail_list status column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
debug
(CheckLogFile, check_logfile)¶show-all
(CheckLogFile, check_logfile)¶empty-state
(CheckLogFile, check_logfile)¶perf-config
(CheckLogFile, check_logfile)¶escape-html
(CheckLogFile, check_logfile)¶help
(CheckLogFile, check_logfile)¶help-pb
(CheckLogFile, check_logfile)¶show-default
(CheckLogFile, check_logfile)¶help-short
(CheckLogFile, check_logfile)¶top-syntax
(CheckLogFile, check_logfile)¶Key | Value |
count | Number of items matching the filter. Common option for all checks. |
total | Total number of items. Common option for all checks. |
ok_count | Number of items matched the ok criteria. Common option for all checks. |
warn_count | Number of items matched the warning criteria. Common option for all checks. |
crit_count | Number of items matched the critical criteria. Common option for all checks. |
problem_count | Number of items matched either warning or critical criteria. Common option for all checks. |
list | A list of all items which matched the filter. Common option for all checks. |
ok_list | A list of all items which matched the ok criteria. Common option for all checks. |
warn_list | A list of all items which matched the warning criteria. Common option for all checks. |
crit_list | A list of all items which matched the critical criteria. Common option for all checks. |
problem_list | A list of all items which matched either the critical or the warning criteria. Common option for all checks. |
detail_list | A special list with critical, then warning and finally ok. Common option for all checks. |
status | The returned status (OK/WARN/CRIT/UNKNOWN). Common option for all checks. |
ok-syntax
(CheckLogFile, check_logfile)¶empty-syntax
(CheckLogFile, check_logfile)¶Key | Value |
count | Number of items matching the filter. Common option for all checks. |
total | Total number of items. Common option for all checks. |
ok_count | Number of items matched the ok criteria. Common option for all checks. |
warn_count | Number of items matched the warning criteria. Common option for all checks. |
crit_count | Number of items matched the critical criteria. Common option for all checks. |
problem_count | Number of items matched either warning or critical criteria. Common option for all checks. |
list | A list of all items which matched the filter. Common option for all checks. |
ok_list | A list of all items which matched the ok criteria. Common option for all checks. |
warn_list | A list of all items which matched the warning criteria. Common option for all checks. |
crit_list | A list of all items which matched the critical criteria. Common option for all checks. |
problem_list | A list of all items which matched either the critical or the warning criteria. Common option for all checks. |
detail_list | A special list with critical, then warning and finally ok. Common option for all checks. |
status | The returned status (OK/WARN/CRIT/UNKNOWN). Common option for all checks. |
detail-syntax
(CheckLogFile, check_logfile)¶column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
perf-syntax
(CheckLogFile, check_logfile)¶column1 column2 column3 column4 column5 column6 column7 column8 column9 file filename line column() Syntax: column(<coulmn number>) ================================
line-split
(CheckLogFile, check_logfile)¶column-split
(CheckLogFile, check_logfile)¶split
(CheckLogFile, check_logfile)¶file
(CheckLogFile, check_logfile)¶files
(CheckLogFile, check_logfile)¶/settings/logfile
(CheckLogFile)¶LOG FILE SECTION
Section for log file checkerSample:
# LOG FILE SECTION # Section for log file checker [/settings/logfile]
/settings/logfile/real-time
(CheckLogFile)¶CONFIGURE REALTIME CHECKING
A set of options to configure the real time checks
Key Default Value Description enabled
0 REAL TIME CHECKING Sample:
# CONFIGURE REALTIME CHECKING # A set of options to configure the real time checks [/settings/logfile/real-time] enabled=0
enabled
(CheckLogFile, /settings/logfile/real-time)¶REAL TIME CHECKING
Spawns a background thread which waits for file changes.Path: /settings/logfile/real-time
Key: enabled
Default value: 0
Used by:
CheckLogFile
Sample:
[/settings/logfile/real-time] # REAL TIME CHECKING enabled=0