Detailed configuration application FileBeats

A, FileBeats Features

1. Read the log file, but do not do data analysis processing

2. ensure that the data "At Least Once" is read at least once, that data is not lost, in some cases repeated consumer

3. Other capabilities: multi-line data processing, data parsing Json simple filtering

Second, the general structure of the configuration file

6 OutPut previous versions can have multiple, after consideration of performance in only one

Third, the common input type configuration Introduction

1. Standard Input

Syntax:

filebeat.inputs:
  - type: stdin
...

The common configuration options can be accessed:

encoding specifies the encoding

exclude_lines ignore the rules of regular matches to the line, exclude_lines: [ '^ DBG'] omit DBG beginning of the line, with no default, but blank lines are ignored

In contrast to the above rule include_lines, and when these options appear together, the high priority option, regardless of the order of configuration file

Max_bytese maximum number of bytes of data in a single, more than would be discarded, the default 10MB

2.log input

Syntax

filebeat.inputs: 
- type: log 
  Paths: 
    - / var / log / messages 
    - /var/log/*.log 
conventional configuration options can be accessed the same as above :( some not listed)
Paths specified file available wildcards, each path line and preceded by a -
recursive_glob.enabled enable wild e.g. recursive / foo / ** may be / foo, / foo / *, / foo / * / * , etc., is enabled by default
exclude_files ignored files

Fourth, the common output type configuration Introduction

1. Standard Output

Syntax

output.console: 
  Pretty: to true 
common configuration options can be accessed:
Pretty landscaping json output 
codec json default output format may be set to change from

the other output subsequent updates




 

Guess you like

Origin www.cnblogs.com/jedi1995/p/11241509.html