Logstash start with error: Pipelines YAML file is empty

If have isntalled the logstash recently using brew, just try going to

cd /usr/local/logstash/{version-number}

and run


bin/logstash -f "/path/to/your/pipeline/config.conf" --config.reload.automatic

brew service restart logstash

Source: https://www.elastic.co/guide/en/logstash/current/advanced-pipeline.html


Looks like you're trying to start your Logstash with multiple pipelines configuration:

When you start Logstash without arguments, it will read the pipelines.yml file and instantiate all pipelines specified in the file. On the other hand, when you use -e or -f, Logstash ignores the pipelines.yml file and logs a warning about it.

You can start Logstash specifying config file location:

logstash -f mypipeline.conf

or you can just configure your pipelines.yml file. I strongly advise to use pipelines configuration becuase it will be easier to expand Logstash in the future and you can specify resources for each pipeline.

An example configuration of pipelines.yml:

- pipeline.id: my_pipeline_name
  path.config: "/path/to/your/config/file.cfg"
  queue.type: persisted