Problems with run logstash as a service

Hi everyone,

I am not be able to run logstash as a service. When i run the command 'sudo systemctl start logstash.service', the status of logstash change to active (running) but it isn't true.

When I check the status of the service, tha activation date always change. In /var/log/logstash/logstash-plain.log I find this error

[2020-03-19T16:24:57,853][ERROR][logstash.configmanagement.bootstrapcheck] There are config files (1) in the '/etc/logstash/conf.d/' folder. Elasticsearch is co nfigured as the config store so configs cannot be sourced via the command line w ith -f or via logstash.yml with path.config
[2020-03-19T16:24:57,932][ERROR][org.logstash.Logstash ] java.lang.IllegalSta teException: Logstash stopped processing because of an error: (SystemExit) exit

I don't understand what does it mean.

When I run logstash manually ('bin/logstash -f /etc/logstash/conf.d/beats.conf') it works well

Could someone help me?

Thanks

It sounds like you may have xpack.management.enabled, telling logstash to store its configuration in elasticsearch, but also have configuration files on disk. logstash is unwilling to resolve the possible ambiguity itself. You need to either remove the files or change that xpack setting to false.

You are right. It works.

Thanks a lot!