filebeat.yml 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. ###################### Filebeat Configuration Example #########################
  2. # This file is an example configuration file highlighting only the most common
  3. # options. The filebeat.full.yml file from the same directory contains all the
  4. # supported options with more comments. You can use it as a reference.
  5. #
  6. # You can find the full configuration reference here:
  7. # https://www.elastic.co/guide/en/beats/filebeat/index.html
  8. #=========================== Filebeat prospectors =============================
  9. filebeat.prospectors:
  10. # Each - is a prospector. Most options can be set at the prospector level, so
  11. # you can use different prospectors for various configurations.
  12. # Below are the prospector specific configurations.
  13. - input_type: log
  14. # Paths that should be crawled and fetched. Glob based paths.
  15. paths:
  16. - "/root/nginx/*.log"
  17. - "/root/docker/*/*.log"
  18. - "/root/php7/*.log"
  19. #- c:\programdata\elasticsearch\logs\*
  20. # Exclude lines. A list of regular expressions to match. It drops the lines that are
  21. # matching any regular expression from the list.
  22. #exclude_lines: ["^DBG"]
  23. # Include lines. A list of regular expressions to match. It exports the lines that are
  24. # matching any regular expression from the list.
  25. #include_lines: ["^ERR", "^WARN"]
  26. # Exclude files. A list of regular expressions to match. Filebeat drops the files that
  27. # are matching any regular expression from the list. By default, no files are dropped.
  28. #exclude_files: [".gz$"]
  29. # Optional additional fields. These field can be freely picked
  30. # to add additional information to the crawled log files for filtering
  31. #fields:
  32. # level: debug
  33. # review: 1
  34. ### Multiline options
  35. # Mutiline can be used for log messages spanning multiple lines. This is common
  36. # for Java Stack Traces or C-Line Continuation
  37. # The regexp Pattern that has to be matched. The example pattern matches all lines starting with [
  38. #multiline.pattern: ^\[
  39. # Defines if the pattern set under pattern should be negated or not. Default is false.
  40. #multiline.negate: false
  41. # Match can be set to "after" or "before". It is used to define if lines should be append to a pattern
  42. # that was (not) matched before or after or as long as a pattern is not matched based on negate.
  43. # Note: After is the equivalent to previous and before is the equivalent to to next in Logstash
  44. #multiline.match: after
  45. #================================ General =====================================
  46. # The name of the shipper that publishes the network data. It can be used to group
  47. # all the transactions sent by a single shipper in the web interface.
  48. #name:
  49. # The tags of the shipper are included in their own field with each
  50. # transaction published.
  51. #tags: ["service-X", "web-tier"]
  52. # Optional fields that you can specify to add additional information to the
  53. # output.
  54. #fields:
  55. # env: staging
  56. #================================ Outputs =====================================
  57. # Configure what outputs to use when sending the data collected by the beat.
  58. # Multiple outputs may be used.
  59. #-------------------------- Elasticsearch output ------------------------------
  60. output.elasticsearch:
  61. # Array of hosts to connect to.
  62. hosts: ["elk-es:9200"]
  63. # Optional protocol and basic auth credentials.
  64. #protocol: "https"
  65. username: "elastic"
  66. password: "changeme"
  67. #----------------------------- Logstash output --------------------------------
  68. #output.logstash:
  69. # The Logstash hosts
  70. #hosts: ["elk-logstash:5044"]
  71. # Optional SSL. By default is off.
  72. # List of root certificates for HTTPS server verifications
  73. #ssl.certificate_authorities: ["/etc/pki/root/ca.pem"]
  74. # Certificate for SSL client authentication
  75. #ssl.certificate: "/etc/pki/client/cert.pem"
  76. # Client Certificate Key
  77. #ssl.key: "/etc/pki/client/cert.key"
  78. #================================ Logging =====================================
  79. # Sets log level. The default log level is info.
  80. # Available log levels are: critical, error, warning, info, debug
  81. #logging.level: debug
  82. # At debug level, you can selectively enable logging only for some components.
  83. # To enable all selectors use ["*"]. Examples of other selectors are "beat",
  84. # "publish", "service".
  85. #logging.selectors: ["*"]