Hi i'm having trouble with this filebeat.yml configuration

i'm having this kind of error and i don't have any other solutions anymore on how to fix this things up. Kindly please help me

Error Initialising publisher: beat.go:161: CRIT No outputs are defined. Please define one under the output section.
beat.go:161: CRIT No outputs are defined. Please define one under the output section.

here is my filebeat.yml file

filebeat:
prospectors: "-i"
paths:
- /var/log/*.log
- /var/log/secure
- /var/log/messages
document_type: syslog

     paths:
     - /var/log/app/*.log
     document_type: app-access

Elasticsearch as output

elasticsearch:

# Array of hosts to connect to.
# Scheme and port can be left out and will be set to the default (http and 9200)
# In case you specify and additional path, the scheme is required: http://localhost:9200/path
# IPv6 addresses should always be defined as: https://[2001:db8::1]:9200
#hosts: ["192.168.0.30:9200"]

tls configuration. By default is off.

#tls:
  # List of root certificates for HTTPS server verifications
  #certificate_authorities: ["/etc/pki/tls/certs/logstash-forwarder.crt"]

  # Certificate for TLS client authentication
  #certificate: "/etc/pki/client/cert.pem"

  # Client Certificate Key
  #certificate_key: "/etc/pki/client/cert.key"

Logstash as output

logstash:

The Logstash hosts

hosts: ["localhost:5044"]
bulk_max_size: 1024

# Number of workers per Logstash host.
#worker: 1

# The maximum number of events to bulk into a single batch window. The
# default is 2048.
#bulk_max_size: 2048

# Set gzip compression level.

#compression_level: 3

# Optional load balance the events between the Logstash hosts

#loadbalance: true

# Optional index name. The default index name depends on the each beat.
# For Packetbeat, the default is set to packetbeat, for Topbeat
# top topbeat and for Filebeat to filebeat.

#index: filebeat

# Optional TLS. By default is off.
tls:
  # List of root certificates for HTTPS server verifications
  certificate_authorities: ["/etc/pki/tls/certs/logstash-forwarder.crt"]

  # Certificate for TLS client authentication
  #certificate: "/etc/pki/client/cert.pem"

  # Client Certificate Key
  #certificate_key: "/etc/pki/client/cert.key"

File as output

file:
# Path to the directory where to save the generated files. The option is mandatory.
path: "/tmp/filebeat"

# Name of the generated files. The default is `filebeat` and it generates files: `filebeat`, `filebeat.1`, `filebeat.2`, etc.
#filename: filebeat

# Maximum size in kilobytes of each file. When this size is reached, the files are
# rotated. The default value is 10 MB.
#rotate_every_kb: 10000

# Maximum number of files under path. When this number of files is reached, the
# oldest file is deleted and the rest are shifted from last to first. The default
# is 7 files.
#number_of_files: 7

Console output

console:

# Pretty print json event
#pretty: false

Someone, please help me. Thank you very much :frowning:

please properly format you config using the </> button. Error message suggest you have no output enabled or indentation is off.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.