I wanna restart logstash, but I get multiple instance error

Hi.
I have a critical problem to me.

When I start Logstash at first, It works well.
But after Killing the logstash and restarting, I have a error message.
When I turn off and on ubuntu again, then It works well again.
I want to restart same logstash instance after exiting logstash without turning Ubuntu back on.
One thing that I need to notice is that path.data should use '/var/Json'.

This is my command to start logstash.

sudo /usr/share/logstash/bin/logstash -f /etc/logstash/conf.d/logstash.conf --path.settings /etc/logstash --path.data /var/Json --config.reload.automatic

This is error message.

Sending Logstash logs to /var/log/logstash which is now configured via log4j2.properties [2020-01-25T01:30:57,592][WARN ][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified [2020-01-25T01:30:57,646][FATAL][logstash.runner ] Logstash could not be started because there is already another instance using the configured data directory. If you wish to run multiple instances, you must change the "path.data" setting. [2020-01-25T01:30:57,664][ERROR][org.logstash.Logstash ] java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit

Thanks.

There might be another existing logstash that’s using the same data directory.

Yes. Even if I kill the logstash, it doesn’t work well..I think that’s the reason that looks like logstash is still running and get a error message. I don’t know how can I kill the logstash at all. (I use kill -9 or kill-15)

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