zoukankan      html  css  js  c++  java
  • filebeat-6.4.3-windows-x86_64输出Kafka

    配置filebeat.yml文件

    filebeat.prospectors:
    
    - type: log
      encoding: utf-8
      enabled: true
      paths:
        - e:log.log
      multiline:
        pattern: '^['
        negate: true
        match: after
      fields:
      log_topics: test1
    
        
    #============================= Filebeat modules ===============================
    
    filebeat.config.modules:
      # Glob pattern for configuration loading
      path: ${path.config}/modules.d/*.yml
    
      # Set to true to enable config reloading
      reload.enabled: false
    
      # Period on which files under path should be checked for changes
      #reload.period: 10s
    
    #==================== Elasticsearch template setting ==========================
    
    #setup.template.settings:
    #  index.number_of_shards: 3
      #index.codec: best_compression
      #_source.enabled: false
    
    
    #setup.kibana:
    
      # Kibana Host
      # Scheme and port can be left out and will be set to the default (http and 5601)
      # In case you specify and additional path, the scheme is required: http://localhost:5601/path
      # IPv6 addresses should always be defined as: https://[2001:db8::1]:5601
      #host: "localhost:5601"
    
    
    #================================ Outputs =====================================
    
    # Configure what output to use when sending the data collected by the beat.
    
    #-------------------------- Elasticsearch output ------------------------------
    
    output.kafka: 
        enabled: true 
        hosts: ["127.0.0.1:9092"]
        topic: test1
        max_message_bytes: 10485760 

    启动

    .filebeat -e -c filebeat.yml 就可以启动filebeat
  • 相关阅读:
    jquery获取当前时间比较日期
    php获取时间计算时间差
    计数查询统计
    jQuery选取所有复选框被选中的值并用Ajax异步提交数据
    在java中实现对access数据库的远程访问
    sublime快捷键
    局部变量和成员变量的区别
    常见的几种数组排序方法
    JVM的内存划分
    Java函数
  • 原文地址:https://www.cnblogs.com/zhanchaohan/p/10281164.html
Copyright © 2011-2022 走看看