Facing issue with logstash command java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit

C:\Users\Abhishek\Desktop\elasticSearch\projectdata\logstash-6.4.3\bin>logstash -f logstash-simple.conf
Sending Logstash logs to C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logs which is now configured via log4j2.properties
[2019-08-10T17:06:41,841][FATAL][logstash.runner ] An unexpected error occurred! {:error=>#<ArgumentError: Setting "logstash.command" hasn't been registered>, :backtrace=>["C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/settings.rb:36:in get_setting'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/settings.rb:69:inset_value'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/settings.rb:88:in block in merge'", "org/jruby/RubyHash.java:1343:ineach'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/settings.rb:88:in merge'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/settings.rb:137:invalidate_all'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/runner.rb:278:in execute'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/vendor/bundle/jruby/2.3.0/gems/clamp-0.6.5/lib/clamp/command.rb:67:inrun'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/runner.rb:237:in run'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/vendor/bundle/jruby/2.3.0/gems/clamp-0.6.5/lib/clamp/command.rb:132:inrun'", "C:\Users\Abhishek\Desktop\elasticSearch\projectdata\logstash-6.4.3\lib\bootstrap\environment.rb:73:in `'"]}
[2019-08-10T17:06:41,875][ERROR][org.logstash.Logstash ] java.lang.IllegalStateException: Logstash stopped processing because of an error: (SystemExit) exit

I would guess that you have a line in logstash.yml that starts with

logstash.command:

There is no such configuration setting, so you should comment it out and retry.

thnaks a lot. above error is fixed now.
I am new to this, again I am facing another error.

PS C:\Users\Abhishek\Desktop\elasticSearch\projectdata\logstash-6.4.3> .\bin\logstash.bat -f .\bin\logstash-sample.conf
Sending Logstash logs to C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logs which is now configured via log4j2.properties
[2019-08-10T18:46:11,042][WARN ][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified
[2019-08-10T18:46:12,093][INFO ][logstash.runner ] Starting Logstash {"logstash.version"=>"6.4.3"}
[2019-08-10T18:46:13,312][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"LogStash::ConfigurationError", :message=>"Expected one of #, { at line 10, column 9 (byte 218) after output {\n elasticsearch { hosts => ["localhost:9200"] }\n index ", :backtrace=>["C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/compiler.rb:41:in compile_imperative'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/compiler.rb:49:incompile_graph'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/compiler.rb:11:in block in compile_sources'", "org/jruby/RubyArray.java:2486:inmap'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/compiler.rb:10:in compile_sources'", "org/logstash/execution/AbstractPipelineExt.java:149:ininitialize'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/pipeline.rb:22:in initialize'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/pipeline.rb:90:ininitialize'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/pipeline_action/create.rb:38:in execute'", "C:/Users/Abhishek/Desktop/elasticSearch/projectdata/logstash-6.4.3/logstash-core/lib/logstash/agent.rb:309:inblock in converge_state'"]}
[2019-08-10T18:46:14,160][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
PS C:\Users\Abhishek\Desktop\elasticSearch\projectdata\logstash-6.4.3>

Remove the } after ["localhost:9200"]. That ends the elasticsearch filter but you need the index option to be part of it.

Thanks you very much!!!
Issue is fixed now.

trying to use csv file now to parse and load.

facing issue and getting below error
[2019-08-19T14:27:41,342][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"Java:
:JavaLang::NoSuchMethodError", :message=>"org.apache.commons.codec.binary.Hex.encodeHexString([B)Ljava/lang/String;", :backtrace=>["org.logstash.execution.AbstractP
ipelineExt.initialize(AbstractPipelineExt.java:124)", "org.logstash.execution.AbstractPipelineExt$INVOKER$i$3$0$initialize.call(AbstractPipelineExt$INVOKER$i$3$0$in
itialize.gen)", "org.jruby.internal.runtime.methods.JavaMethod$JavaMethodThree.call(JavaMethod.java:1186)", "org.jruby.internal.runtime.methods.JavaMethod$JavaMetho
dN.call(JavaMethod.java:743)", "org.jruby.ir.runtime.IRRuntimeHelpers.instanceSuper(IRRuntimeHelpers.java:983)", "org.jruby.ir.runtime.IRRuntimeHelpers.instanceSupe
rSplatArgs(IRRuntimeHelpers.java:974)", "org.jruby.ir.targets.InstanceSuperInvokeSite.invoke(InstanceSuperInvokeSite.java:39)", "C_3a_.Users.abhishek12_dot_jain.Doc
uments.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logstash.pipeline.RUBY$method$initialize$0(C:/Users/abhishek1
2.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/pipeline.rb:22)", "org.jruby.internal.runtime.methods.Compiled
IRMethod.call(CompiledIRMethod.java:77)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:93)", "org.jruby.ir.runtime.IRRuntimeHel
pers.instanceSuper(IRRuntimeHelpers.java:983)", "org.jruby.ir.runtime.IRRuntimeHelpers.instanceSuperSplatArgs(IRRuntimeHelpers.java:974)", "org.jruby.ir.targets.Ins
tanceSuperInvokeSite.invoke(InstanceSuperInvokeSite.java:39)", "C_3a_.Users.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_
6_dot_5_dot_4.logstash_minus_core.lib.logstash.pipeline.RUBY$method$initialize$0(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logst
ash-6.5.4/logstash-core/lib/logstash/pipeline.rb:90)", "org.jruby.internal.runtime.methods.CompiledIRMethod.call(CompiledIRMethod.java:77)", "org.jruby.internal.run
time.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:93)", "org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:298)", "org.jruby.run
time.callsite.CachingCallSite.callBlock(CachingCallSite.java:79)", "org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:83)", "org.jruby.RubyClass.
newInstance(RubyClass.java:1022)", "org.jruby.RubyClass$INVOKER$i$newInstance.call(RubyClass$INVOKER$i$newInstance.gen)", "org.jruby.ir.targets.InvokeSite.invoke(In
vokeSite.java:145)", "C_3a_.Users.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logs
tash.pipeline_action.create.RUBY$block$execute$1(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logs
tash/pipeline_action/create.rb:42)", "org.jruby.runtime.CompiledIRBlockBody.callDirect(CompiledIRBlockBody.java:145)", "org.jruby.runtime.IRBlockBody.call(IRBlockBo
dy.java:71)", "org.jruby.runtime.Block.call(Block.java:124)", "org.jruby.RubyProc.call(RubyProc.java:289)", "org.jruby.RubyProc.call19(RubyProc.java:273)", "org.jru
by.RubyProc$INVOKER$i$0$0$call19.call(RubyProc$INVOKER$i$0$0$call19.gen)", "org.jruby.ir.targets.InvokeSite.invoke(InvokeSite.java:145)", "C_3a_.Users.abhishek12_do
t_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logstash.agent.RUBY$block$exclusive$1(C:/Users/abhi
shek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/agent.rb:92)", "org.jruby.runtime.CompiledIRBlockBody.yie
ldDirect(CompiledIRBlockBody.java:156)", "org.jruby.runtime.IRBlockBody.yieldSpecific(IRBlockBody.java:80)", "org.jruby.runtime.Block.yieldSpecific(Block.java:134)"
, "org.jruby.ext.thread.Mutex.synchronize(Mutex.java:148)", "org.jruby.ext.thread.Mutex$INVOKER$i$0$0$synchronize.call(Mutex$INVOKER$i$0$0$synchronize.gen)", "org.j
ruby.internal.runtime.methods.JavaMethod$JavaMethodZeroBlock.call(JavaMethod.java:498)", "org.jruby.ir.targets.InvokeSite.invoke(InvokeSite.java:145)", "C_3a_.Users
.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logstash.agent.RUBY$method$exclusive$
0(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/agent.rb:92)", "C_3a_.Users.abhishek12_dot
jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logstash.agent.RUBY$method$exclusive$0$VARARGS(C
:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/agent.rb)", "org.jruby.internal.runtime.metho
ds.CompiledIRMethod.call(CompiledIRMethod.java:77)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:93)", "org.jruby.ir.targets.I
nvokeSite.invoke(InvokeSite.java:145)", "C_3a
.Users.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_
minus_core.lib.logstash.pipeline_action.create.RUBY$method$execute$0(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/lo
gstash-core/lib/logstash/pipeline_action/create.rb:38)", "C_3a_.Users.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_
5_dot_4.logstash_minus_core.lib.logstash.pipeline_action.create.RUBY$method$execute$0$VARARGS(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Developme
nt/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/pipeline_action/create.rb)", "org.jruby.internal.runtime.methods.CompiledIRMethod.call(CompiledIRMethod.java:7
7)", "org.jruby.internal.runtime.methods.MixedModeIRMethod.call(MixedModeIRMethod.java:93)", "org.jruby.ir.targets.InvokeSite.invoke(InvokeSite.java:145)", "C_3a_.U
sers.abhishek12_dot_jain.Documents.ProjectData_JCP.Skill_Development.ELKSetup.logstash_minus_6_dot_5_dot_4.logstash_minus_core.lib.logstash.agent.RUBY$block$converg
e_state$2(C:/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/logstash-core/lib/logstash/agent.rb:317)", "org.jruby.runtime
.CompiledIRBlockBody.callDirect(CompiledIRBlockBody.java:145)", "org.jruby.runtime.IRBlockBody.call(IRBlockBody.java:71)", "org.jruby.runtime.Block.call(Block.java:
124)", "org.jruby.RubyProc.call(RubyProc.java:289)", "org.jruby.RubyProc.call(RubyProc.java:246)",

conf I am using

input {
file {
path => ["/Users/abhishek12.jain/Documents/ProjectData_JCP/Skill_Development/ELKSetup/logstash-6.5.4/bin/cars.csv"]
start_position => "beginning"
sincedb_path => "nul"
}
}

filter {
csv {
separator => ","
columns => ["maker","model","mileage","manufacture_year","engine_displacement","engine_power","body_type","color_slug","stk_year","transmission","door_count","seat_count","fuel_type","date_created","date_last_seen","price_eur"]
}
mutate {convert => ["mileage","integer"]}
mutate {convert => ["price_eur","float"]}
mutate {convert => ["engine_power","integer"]}
mutate {convert => ["door_count","integer"]}
mutate {convert => ["seat_count","integer"]}
}

output {
elasticsearch { hosts => ["localhost:9200"]
index => "secondindex"
document_type => "sold_cars"
}
stdout {codec => rubydebug}
}