# Unable to parse multiple format logs

**URL:** https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088
**Category:** Logstash
**Created:** [May 24, 2018, 8:05am UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088 "2018-05-24T08:05:27Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Saketh\_Chandra\_Kolis](https://avatars.discourse-cdn.com/v4/letter/s/58956e/32.png) [@Saketh\_Chandra\_Kolis](https://discuss.elastic.co/u/Saketh_Chandra_Kolis)
#### Post date: [May 24, 2018, 8:05am UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088/1 "2018-05-24T08:05:27Z")

</div>

```
here is my full configuration:

```

input {  
file {  
type =\> "apache"  
path =\> "C:/Users/Mahe/Desktop/intership/apache.log"  
}  
file {  
type =\> "csvf"  
path =\> "C:/data/cars.csv"  
}  
}  
filter {  
if [type] == "apache" {  
grok {  
match =\> [  
"message" , "%{COMBINEDAPACHELOG}+%{GREEDYDATA:extra\_fields}",  
"message" , "%{COMMONAPACHELOG}+%{GREEDYDATA:extra\_fields}"  
]  
overwrite =\> ["message"]  
}  
mutate {  
convert =\> ["response", "integer"]  
convert =\> ["bytes", "integer"]  
convert =\> ["responsetime", "float"]  
}  
geoip {  
source =\> "clientip"  
target =\> "geoip"  
add\_tag =\> ["apache-geoip"]  
}  
date {  
match =\> ["timestamp" , "dd/MMM/YYYY:HH:mm:ss Z"]  
remove\_field =\> ["timestamp"]  
}  
useragent {  
source =\> "agent"  
}  
}  
if [type] == "csvf" {  
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 {  
if [type] == "apache" {  
elasticsearch {  
hosts =\> "localhost"  
index=\>"apa"  
document\_type=\>"apacsvd"  
}  
stdout{}  
}  
if [type] == "csvf" {  
elasticsearch {  
hosts =\> "localhost"  
index=\>"csvf"  
document\_type=\>"apacsvd"  
}  
stdout{}

```
}

```

}  
however when i try to parse them individually it works just fine

---

<div class="post-metadata">

### Author: ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)
#### Post date: [May 27, 2018, 7:55pm UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088/2 "2018-05-27T19:55:00Z")

</div>

Okay, but in what way is it not working now? What is the symptom?

---

<div class="post-metadata">

### Author: ![Saketh\_Chandra\_Kolis](https://avatars.discourse-cdn.com/v4/letter/s/58956e/32.png) [@Saketh\_Chandra\_Kolis](https://discuss.elastic.co/u/Saketh_Chandra_Kolis)
#### Post date: [May 28, 2018, 4:49am UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088/3 "2018-05-28T04:49:49Z")

</div>

the pipeline gets started but logs are not parsed.

---

<div class="post-metadata">

### Author: ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)
#### Post date: [May 28, 2018, 5:43am UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088/4 "2018-05-28T05:43:04Z")

</div>

How are you starting Logstash when it's **not** working? How are you starting Logstash when it **is** working? Have you tried bumping up Logstash's loglevel and looked in its log for clues?

---

<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: [June 25, 2018, 5:43am UTC](https://discuss.elastic.co/t/unable-to-parse-multiple-format-logs/133088/5 "2018-06-25T05:43:06Z")

</div>

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