Logstash takes wrong pipeline.yml when startin on CLI


#1

Hi all,
I am testing Logstash with mutliple pipelines.
So I have set my pipelines in /etc/logstash/pipelines.yml.
When I start logstash in foreground with
/usr/share/logstash/bin/logstash
I got the error: ERROR: Failed to read pipelines yaml file. Location: /usr/share/logstash/config/pipelines.yml
Why does logstash try to take the file in /usr/share/logstash/config and how can I set the path right, to check if my multi pipelines run correct? When I run logstash with -e or -f the pipelines.yml is ignored.


(Magnus Bäck) #2

I suspect https://www.elastic.co/guide/en/logstash/current/dir-layout.html will answer your questions.


#3

not really because I installed logtsash with packages (ubuntu 18.04) so the default pipeline path should be /etc/logstash/pipelines.yml. When I start logstash as a service, everything works fine. Only when I start /usr/share/logstash/bin/logstash in foreground on CLI it does not work.


(Magnus Bäck) #4

I see. I wonder if the directory defaults for Debian-based Logstash installations only apply when running it as a service. For interactive use you may have to set the settings path via --path.settings or the LS_SETTINGS_DIR environment variable. See https://www.elastic.co/guide/en/logstash/current/running-logstash-command-line.html.


#5

I see --path.settings works fine. Thanks Magnus!


(system) #6

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