# "failed parsing time field" + "failed using layout"

**URL:** <https://discuss.elastic.co/t/failed-parsing-time-field-failed-using-layout/262433>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [January 28, 2021, 12:23am UTC](https://discuss.elastic.co/t/failed-parsing-time-field-failed-using-layout/262433 "2021-01-28T00:23:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![6NMgfDwZ3](https://avatars.discourse-cdn.com/v4/letter/6/ac91a4/32.png) [@6NMgfDwZ3](https://discuss.elastic.co/u/6NMgfDwZ3)\
**Post date:** [January 28, 2021, 12:23am UTC](https://discuss.elastic.co/t/failed-parsing-time-field-failed-using-layout/262433/1 "2021-01-28T00:23:08Z")

</div>

Hello,

I am trying to convert a microseconds precision time field to @timestamp but I got error messages.

A part of the Filebeat config lines, related to the issue:

```auto
processors:
  - decode_json_fields:
     fields: ["message"]
     process_array: true
     target: ""
     add_error_key: true
     overwrite_keys: true
  - timestamp:
      field: mytimestamp
      layouts:
        - '2020-01-02T12:34:56.123456Z'

```

and here is the error message from Filebeat log (debug level):

```auto
    2021-01-27T22:45:04.020+0100 DEBUG [processor.timestamp] timestamp/timestamp.go:173 Failure parsing time field. {"error": "failed parsing time field mytimestamp='2021-01-27T21:45:04.003313Z'", "errorCauses": [{"error": "failed using layout [2020-01-02T12:34:56.123456Z] cannot parse [-01-27T21:45:04.003313Z] as [0-]"}]}

    2021-01-27T22:45:04.020+0100 DEBUG [processors] processing/processors.go:128 Fail to apply processor global{decode_json_fields=message, timestamp=[field=mytimestamp, target_field=@timestamp, timezone=UTC, layouts=[2020-01-02T12:34:56.123456Z]]}: failed parsing time field mytimestamp='2021-01-27T21:45:04.003313Z'

```

Versions:  
Elasticsearch 7.10.2  
Kibana: 7.10.2  
FileBeat: 7.10.2

Does anybody has an idea what is wrong with the above time and with the layout?

---

<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 25, 2021, 2:23am UTC](https://discuss.elastic.co/t/failed-parsing-time-field-failed-using-layout/262433/2 "2021-02-25T02:23:22Z")

</div>

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