filebeat: # List of prospectors to fetch data. prospectors: # Each - is a prospector. Below are the prospector specific configurations - # Paths that should be crawled and fetched. Glob based paths. # To fetch all ".log" files from a specific level of subdirectories # /var/log/*/*.log can be used. # For each file found under this path, a harvester is started. # Make sure not file is defined twice as this can lead to unexpected behaviour. # 指定要监控的日志,可以指定具体得文件或者目录 paths: - /var/log/*.log # 这是默认的,自行可以修改,比如可以放在 /logs/localhost_access_* #- c:\programdata\elasticsearch\logs\*
# Configure the file encoding for reading files with international characters # following the W3C recommendation for HTML5 (http://www.w3.org/TR/encoding). # Some sample encodings: # plain, utf-8, utf-16be-bom, utf-16be, utf-16le, big5, gb18030, gbk, # hz-gb-2312, euc-kr, euc-jp, iso-2022-jp, shift-jis, ... # 指定被监控的文件的编码类型,使用plain和utf-8都是可以处理中文日志的 #encoding: plain
# Type of the files. Based on this the way the file is read is decided. # The different types cannot be mixed in one prospector # # Possible options are: # * log: Reads every line of the log file (default) # * stdin: Reads the standard in # 指定文件的输入类型log(默认)或者stdin input_type: log
# Exclude lines. A list of regular expressions to match. It drops