I am able to run logstash as:
bin/logstash -f /etc/logstash/conf.d/config.json
but running logstash as a service
sudo service logstash start
is giving me the following error:
... Error: Expected one of #, input, filter, output at line 24, column 1 (byte 528) after "}
Not sure what I am doing wrong here? Configtest also says the config file is fine.
bin/logstash -f /etc/logstash/conf.d/config.json --configtest
Configuration OK
Any help is appreciated.
Thanks.
When logstash runs, it combines all the files in your config directory into one file. When there's an error, you're getting line and position information into that merged config.
Try:
cat /etc/logstash/conf.d/* > /tmp/total.conf
and then look at line 24 or 25 there.
FYI mine complains about line about line 163 and my combined files don't get that far.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With