[WARN ] 2022-03-29 15:12:27.166 [LogStash::Runner] multilocal - Ignoring the 'pipelines.yml' file because modules or command line options are specified
[FATAL] 2022-03-29 15:12:27.560 [LogStash::Runner] runner - The given configuration is invalid. Reason: Expected one of #, input, filter, output at line 1, column 1 (byte 1)
[ERROR] 2022-03-29 15:12:27.577 [LogStash::Runner] Logstash - java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit
Steps That i tried to fix this :
1.I checked each pipelines it is giving configuration valid and OK .
For ex: sudo bin/logstash --config.test_and_exit -f /etc/logstash/conf.d/dmb_prod.conf By checking this it is giving Ok for all pipelines.
So can someone help how i can know that what particular line is giving me that error ....
And also in the error message at last it is giving : Logstash stopped processing because of an error: (SystemExit) exit.
So is it a error that can effect processing of data in ES. I am ablwe to see data of this running pipelines but it is not consistent.
So also wanted to know about it as well...
When you run sudo bin/logstash --config.test_and_exit -f /etc/logstash/conf.d/dmb_prod.conf it's checking that single config.
When you are running as a service it should utilize pipelines.yml and execute those pipeline (which there might be an error in). So the steps would be to look at the pipelines.yml first and then go to any of the pipelines that are being started by that.
And for checking each pipelines individually it is giving configuration ok status. But with just sudo bin/logstash --config.test_and_exit -f /etc/logstash/conf.d/
The one file you tested dmb_prod.conf isn't in the pipelines.yml file that I see.
What's in here is all the pipeline that will execute when you start Logstash as a service. I would go to each one of these and test. Also I am not quite sure what ## and ### will do. Should just be a single # to comment out a line so it doesn't execute.
I would also clean it up so it only has what you are executing to ensure there is no format or typos with all the comments.
that dmb_prod i used is just fir Example i expressed.
So,
Do i need to run sudo bin/logstash --config.test_and_exit -f /etc/logstash/conf.d/
this command for each pipelins?
and also do i need to run it for json filter as well ?
Do i need to remove ### this type of comments in pipelines .yml ?
Yes. Test the config on any .conf file that is defined in the pipelines.yml
I would remove those comments.
[FATAL] 2022-03-29 15:12:27.560 [LogStash::Runner] runner - The given configuration is invalid. Reason: Expected one of #, input, filter, output at line 1, column 1 (byte 1)
This means the first character in one of those files does not start with one of the below.
I checked for each pipeline individually but all shown configuration OK for all pipelines inside Pipelines.yml
---> do i also need to check .json file with the sudo bin/logstash --config.test_and_exit -f /etc/logstash/conf.d/
this command ?
Is their any way i can find which particular file is causing this error . Because i checked for each .conf file with same command it is giving configuration ok.
When you run it as a service and tail the Logstash log does it give you the same error?
[FATAL] 2022-03-29 15:12:27.560 [LogStash::Runner] runner - The given configuration is invalid. Reason: Expected one of #, input, filter, output at line 1, column 1 (byte 1)
Or does it look different than what you got on the command line? I am asking because I think if you run it as a service it will include the pipeline.id in the error so you know which one it is.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.