# Another one \_dateparsefailure error

**URL:** <https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895>\
**Category:** Logstash\
**Created:** [January 26, 2017, 12:13pm UTC](https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895 "2017-01-26T12:13:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![m0nhawk](https://avatars.discourse-cdn.com/v4/letter/m/9de0a6/32.png) [@m0nhawk](https://discuss.elastic.co/u/m0nhawk)\
**Post date:** [January 26, 2017, 12:13pm UTC](https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895/1 "2017-01-26T12:13:57Z")

</div>

I have the following config:

```
input {
    file {
        path => "/root/logs/test.log"
        type => "accesslog"
        start_position => beginning
        sincedb_path => "/dev/null"
        ignore_older => 0
    }
}
filter {
    grok {
        match => ["message", "(?<datetime>%{YEAR}-%{MONTHNUM}-%{MONTHDAY} %{HOUR}:%{MINUTE}:%{SECOND})"]
    }
    date {
        match => ["datetime", "yyyy:MM:dd HH:mm:ss"]
        target => "@timestamp"
    }
}
output {
    stdout { codec => rubydebug }
}

```

And log (one line for easy checking):

```
2016-10-01 00:00:23

```

And when I run logstash, I get an error:

```
{
          "path" => "/root/logs/test.log",
      "datetime" => "2016-10-01 00:00:23",
    "@timestamp" => 2017-01-26T12:13:01.216Z,
      "@version" => "1",
          "host" => "ax-2",
       "message" => "2016-10-01 00:00:23",
          "type" => "accesslog",
          "tags" => [
        [0] "_dateparsefailure"
    ]
}

```

I have looked for dozens of topics, but have no idea why it is failing. I'm using latest ELK on Ubuntu 14.04.

---

<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:** [January 26, 2017, 12:16pm UTC](https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895/2 "2017-01-26T12:16:00Z")

</div>

Here's your date:

```
2016-10-01 00:00:23

```

Here's your pattern:

```
yyyy:MM:dd HH:mm:ss

```

You have too many colons in your pattern.

---

<div class="post-metadata">

**Author:** ![m0nhawk](https://avatars.discourse-cdn.com/v4/letter/m/9de0a6/32.png) [@m0nhawk](https://discuss.elastic.co/u/m0nhawk)\
**Post date:** [January 26, 2017, 12:24pm UTC](https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895/3 "2017-01-26T12:24:45Z")

</div>

Thanks you! Now everything is works on original config (I've also found few more issues in the grok pattern, thanks to you).

---

<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:** [February 23, 2017, 12:24pm UTC](https://discuss.elastic.co/t/another-one--dateparsefailure-error/72895/4 "2017-02-23T12:24:47Z")

</div>

Closed on February 23, 2017, 12:24pm UTC

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