tencent cloud

Feedback

Customizing Filebeat Data Access

Last updated: 2024-12-04 16:15:17

    Self-Built Filebeat Data Collection

    Version Support Only Filebeat versions 7.10.2 or 7.14.2 are supported.
    Category
    Parameter
    Description
    Filling Instructions
    Elasticsearch template setting
    setup.template.enabled
    Index template
    Boolean type. It can be set to false; currently, this setting is not supported.
    setup.ilm.enabled
    Index lifecycle management
    Boolean type. It can be set to false; currently, this setting is not supported.
    allow_older_versions
    Compatibility with ES versions
    Boolean type. It can be set to true or false.
    output
    protocol
    Data transmission protocol
    String type. The default value is http, and it can also be set to https.
    hosts
    Private network access address for index
    Array type.
    If the protocol is set to http, the port number should be 80. For example, it can be set as ["http://index-xxx.qcloudes.com:80"];
    If the protocol is set to https, the port number should be 443. For example, it can be set as ["https://index-xxx.qcloudes.com:443"].
    Configuration Description
    # ============================== Filebeat inputs ===============================
    
    filebeat.inputs:
    - type: log
    # Change to true to enable this input configuration.
    enabled: true
    # Paths that should be crawled and fetched. Glob based paths.
    paths:
    - /var/log/*.log
    # ============================== 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.enabled: false
    setup.ilm.enabled: false
    #template setting's value is set to false by default. If you set it to true, an error will be reported when the configuration is submitted
    
    
    # ================================== General ===================================
    
    # The name of the shipper that publishes the network data. It can be used to group
    # all the transactions sent by a single shipper in the web interface.
    #name:
    
    # The tags of the shipper are included in their own field with each
    # transaction published.
    #tags: ["service-X", "web-tier"]
    
    # Optional fields that you can specify to add additional information to the
    # output.
    #fields:
    # env: staging
    
    # ================================= Processors =================================
    processors:
    - add_host_metadata:
    when.not.contains.tags: forwarded
    
    # ================================== Logging ===================================
    
    # Sets log level. The default log level is info.
    # Available log levels are: error, warning, info, debug
    #logging.level: debug
    
    # At debug level, you can selectively enable logging only for some components.
    # To enable all selectors use ["*"]. Examples of other selectors are "beat",
    # "publisher", "service".
    #logging.selectors: ["*"]
    ############################# output ######################################
    output.elasticsearch:
    # Array of hosts to connect to.
    allow_older_versions: true
    protocol: "http"
    hosts: ["Private network access address for index"]
    
    # Authentication credentials - either API key or username/password.
    username: "your index username"
    password: "your index password"
    indices:
    - index: The_index_name
    when.equals:
    fields.type: log
    
    
    
    
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support