error while setting filebeat up and make it connect to elastic search

≯℡__Kan透↙ 提交于 2020-03-05 00:31:05

问题


i pulled docker images of filbeat and elastic search. I run the containers. i set the environment variable of elastic search "discovery.type=single-node" in running command.i configured filebeat.yml apache.yml elastisearch.yml. but i am getting following error:

Exiting: Couldn't connect to any of the configured Elasticsearch hosts. Errors: [Error connection to Elasticsearch http://elasticsearch:9200: Get http://elasticsearch:9200: lookup elasticsearch on 192.168.65.1:53: no such host]

my filebeat.yml:

 filebeat.config:
  modules:
    path: ${path.config}/modules.d/apache.yml
    reload.enabled: true

    setup.dashboards.enabled: true
    setup.kibana.host: "http://kibana:5601"

    #processors:
    #- add_cloud_metadata: 

    output.elasticsearch:
      hosts: [ "http://elasticsearch:9200" ]
      #username: '${ELASTICSEARCH_USERNAME:}'
      #password: '${ELASTICSEARCH_PASSWORD:}'

my 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:\Users\saivishal.vangala\Desktop\filbeatdemo

  # Error logs
  error:
    enabled: true

    # Set custom paths for the log files. If left empty,
    # Filebeat will choose the paths depending on your OS.
    #var.paths:

my elasticsearch.yml:

cluster.name: "docker-cluster"
network.host: 0.0.0.0

and when i tried to restart the container of filebeat it is not getting started. i think it is corrupted.

来源:https://stackoverflow.com/questions/60208754/error-while-setting-filebeat-up-and-make-it-connect-to-elastic-search

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!