【问题标题】:Filebeat fails to start when output is set to file当输出设置为文件时,Filebeat 无法启动
【发布时间】:2020-02-24 21:07:13
【问题描述】:

我对 filebeat 和 ELK 堆栈还很陌生。在成功构建 Filebeat、Elastic 和 Kibana 堆栈索引 apache 访问日志文件后,我想使用 Filebeat 将输出发送到文件以进行测试。但是,我一直遇到错误。 Filebeat 启动然后立即再次退出,因为它正在寻找弹性。

日志文件的相关部分如下。

2020-02-20T16:19:40.794+0100    WARN    beater/filebeat.go:152  Filebeat is unable to load the Ingest Node pipelines for the configured modules because the Elasticsearch output is not configured/enabled. If you have already loaded the Ingest Node pipelines or are using Logstash pipelines, you can ignore this warning.
2020-02-20T16:19:40.794+0100    ERROR   instance/beat.go:916    Exiting: Index management requested but the Elasticsearch output is not configured/enabled

下面是使用的filebeat.yml。

#=========================== Filebeat inputs =============================

filebeat.inputs:
- type: log
  enabled: true
  paths:
    - C:\Some\folder\*

#============================= Filebeat modules ===============================

filebeat.config.modules:
  path: C:\another\folder\*.yml
  reload.enabled: true

#------------------------------- File output -----------------------------------
output.file:
  enabled: true
  path: 'C:\Yet\another\folder\'
  filename: filebeat

我还配置了一个 apache.yml

- module: apache
  # Access logs
  access:
    enabled: true

    # Set custom paths for the log files. If left empty,
    # Filebeat will choose the paths depending on your OS.
    var.paths: ['C:\Some\Folder\2\Access*']

Filebeat 一直要求配置弹性输出,但一次只能配置一个输出。 我需要设置一些选项吗? 我正在使用弹性堆栈 7.5

【问题讨论】:

    标签: elasticsearch filebeat


    【解决方案1】:

    可能 Filebeat 正在尝试将 load template 输入 Elasticsearch,但未配置 Elasticsearch 输出。

    通过将以下配置添加到 filebeat.yml 文件来禁用自动模板加载

    setup.template.enabled: false
    

    希望这能解决您的问题。

    【讨论】:

    • 我在 filebeat.yml 中添加了“setup.template.enabled: false”。不幸的是,这并没有解决它。我不断收到同样的错误。
    【解决方案2】:

    显然,需要运行 kibana 才能使 output.file 选项起作用。 在我启动 kibana.bat 并运行 .\filebeat.exe setup --dashboards 之后。错误消失了,filebeat 可以将其输出设置为 file。

    【讨论】:

      猜你喜欢
      • 2021-01-03
      • 1970-01-01
      • 2023-01-05
      • 1970-01-01
      • 1970-01-01
      • 2018-11-05
      • 2020-05-12
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多