logstashで複数起動してないのにlogstash could not be started becasuse there is already instance using the configured data directory.ってでた。

/usr/share/logstash/bin/logstash -f /etc/logstash/conf.d/〇〇.conf --path.settings "/etc/logstash"のコマンドで、


DBのデータを投入しようとしたら、以下のエラーが出ていた。

 

[FATAL][logstash.runner]
logstash could not be started becasuse there is already instance using the configured data directory. If you wish to run multiple instances, you must change the “path.data” setting.
[rog.logstash.Logstash] java.lang.IllegalStateException: Logstash stopped processiog because modules or command line options are specified

 


下記の記事を見る限り、複数のインスタンスを起動する場合起こる現象っぽいですが、複数起動していない。
https://www.mtioutput.com/entry/2019/02/19/180000

 

 

ps axf | grep logstash のコマンドで動いているプロセスを確認してみたところ、ヒットするlogstashプロセスがあった。

よくわからないけどそれをKill -9のコマンドで停止させると動いた。