# Logstash Configuration error - logstash shut down

**URL:** <https://discuss.elastic.co/t/logstash-configuration-error-logstash-shut-down/196801>\
**Category:** Logstash\
**Created:** [August 26, 2019, 3:15pm UTC](https://discuss.elastic.co/t/logstash-configuration-error-logstash-shut-down/196801 "2019-08-26T15:15:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![deemanu](https://avatars.discourse-cdn.com/v4/letter/d/f0a364/32.png) [@deemanu](https://discuss.elastic.co/u/deemanu)\
**Post date:** [August 26, 2019, 3:15pm UTC](https://discuss.elastic.co/t/logstash-configuration-error-logstash-shut-down/196801/1 "2019-08-26T15:15:39Z")

</div>

Hi , I am trying to parse a log line (log file customized by me ) but there is some error msg

Sending Logstash logs to C:/Users/mau/Desktop/ELK/logstash-7.3.0/logs which is now configured via log4j2.properties  
[2019-08-26T11:09:28,232][WARN][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules or command line options are specified  
[2019-08-26T11:09:28,251][INFO][logstash.runner] Starting Logstash {"logstash.version"=\>"7.3.0"}  
[2019-08-26T11:09:29,473][ERROR][logstash.agent] Failed to execute action {:action=\>LogStash::PipelineAction::Create/pipeline\_id:main, :exception=\>"LogStash::ConfigurationError", :message=\>"Expected one of #, =\> at line 11, colum  
=\> [".C:\Users\manu\Desktop\ELK\Patterns\Testpatterns.txt"]\n match =\> { "%{MSG:Message}\s\*\| %{N:RequestedID} %{GREEDYDATA} %{WORD:GetMethod} \| %{N:ResponseTime} %{GREEDYDATA} %{URI:URIRequested} %{GREEDYDATA}  
ATA}" ", :backtrace=\>["C:/Users/manu/Desktop/ELK/logstash-7.3.0/logstash-core/lib/logstash/compiler.rb:41:in `compile_imperative'", "C:/Users/manu/Desktop/ELK/logstash-7.3.0/logstash-core/lib/logstash/compiler.rb:49:i gstash-7.3.0/logstash-core/lib/logstash/compiler.rb:11:in`block in compile\_sources'", "org/jruby/RubyArray.java:2577:in `map'", "C:/Users/manu/Desktop/ELK/logstash-7.3.0/logstash-core/lib/logstash/compiler.rb:10:in`compile\_sour  
in `initialize'", "org/logstash/execution/JavaBasePipelineExt.java:47:in`initialize'", "C:/Users/manu/Desktop/ELK/logstash-7.3.0/logstash-core/lib/logstash/java\_pipeline.rb:24:in `initialize'", "C:/Users/manu/Desktop/ n/create.rb:36:in`execute'", "C:/Users/manu/Desktop/ELK/logstash-7.3.0/logstash-core/lib/logstash/agent.rb:325:in `block in converge\_state'"]}  
[2019-08-26T11:09:29,833][INFO][logstash.agent] Successfully started Logstash API endpoint {:port=\>9600}  
[2019-08-26T11:09:34,909][INFO][logstash.runner] Logstash shut down.

.......................................................

my grok is

input {  
file {  
path =\> ["C:\Users\manu\Desktop\ELK\logstash-7.3.0\config\test.conf"]  
start\_position =\> "beginning"  
}  
}

filter {  
grok {  
patterns\_dir =\> [".C:\Users\manu\Desktop\ELK\Patterns\Testpatterns.txt"]  
match =\> { "%{MSG:Message}\s\*| %{N:RequestedID} %{GREEDYDATA} %{WORD:GetMethod} | %{N:ResponseTime} %{GREEDYDATA} %{URI:URIRequested} %{GREEDYDATA} %{WORD:Responsephrase} %{GREEDYDATA} %{ACC:Action} %{GREEDYDATA}" }  
}  
if "\_grokparserfailure" in [tags] {  
drop{}  
}

output {  
stdout {  
codec =\> rubydebug  
}  
}

I have customized grok pattern ( regex ) which i saved in one location and included path above in patterns\_dir .

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [August 26, 2019, 3:37pm UTC](https://discuss.elastic.co/t/logstash-configuration-error-logstash-shut-down/196801/2 "2019-08-26T15:37:15Z")

</div>

> [@deemanu](#):
>
> ```
> match => { "%{MSG:Message}\s*| %{N:RequestedID} %{GREEDYDATA} %{WORD:GetMethod} | %{N:ResponseTime} %{GREEDYDATA} %{URI:URIRequested} %{GREEDYDATA} %{WORD:Responsephrase} %{GREEDYDATA} %{ACC:Action} %{GREEDYDATA}" }
> 
> ```

You need to tell it what to match that against. For example

```
match => { "message" => "%{MSG:Message}\s*| %{N:RequestedID} %{GREEDYDATA} %{WORD:GetMethod} | %{N:ResponseTime} %{GREEDYDATA} %{URI:URIRequested} %{GREEDYDATA} %{WORD:Responsephrase} %{GREEDYDATA} %{ACC:Action} %{GREEDYDATA}" }

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 23, 2019, 3:37pm UTC](https://discuss.elastic.co/t/logstash-configuration-error-logstash-shut-down/196801/3 "2019-09-23T15:37:16Z")

</div>

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