# Filebeat 7.3 syslog / auth log timezone parsing error

**URL:** <https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [August 21, 2019, 3:43am UTC](https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031 "2019-08-21T03:43:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kent\_Wang](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kent_wang/32/52610_2.png) [@Kent\_Wang](https://discuss.elastic.co/u/Kent_Wang)\
**Post date:** [August 21, 2019, 3:43am UTC](https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031/1 "2019-08-21T03:43:28Z")

</div>

Hi Guys,

I think there is something wrong in the system module ingest pipeline related to timezone processing.

Here is an excerpt of date processors from pipipeline.json:

```
{
    "date": {
        "field": "system.auth.timestamp",
        "target_field": "@timestamp",
        "formats": [
            "MMM d HH:mm:ss",
            "MMM dd HH:mm:ss",
            "ISO8601"
        ],
        "ignore_failure": true
    }
},
{
    "date": {
        "if": "ctx.event.timezone != null",
        "field": "@timestamp",
        "formats": ["ISO8601"],
        "timezone": "{{ event.timezone }}",
        "on_failure": [{"append": {"field": "error.message", "value": "{{ _ingest.on_failure_message }}"}}]
    }
},

```

When the first date processor is executed, the time field is parsed in UTC timezone, then  
the second date processor just adjust @timestamp to event.timezone, which is still wrong.

For example, assume that we have a server in timezone +08:00, and system.auth.timestamp is "Aug 21 11:15:01":

1. the first date processor parses system.auth.timestamp in UTC timezone, which got:  
{  
"@timestamp": "2019-08-21T11:15:01Z"  
}

2. the second date processor parses @timestamp field in +08:00 timezone, which got:  
{  
"@timestamp": "2019-08-21T19:15:01+08:00"  
}

I have a fix here. If it's confirmed as a bug, I'll submit a github issue and pull request.

> <https://github.com/pragkent/beats/commit/031cbe35c0ecd682d9d6d4a74f5bd186ecc05c20>

---

<div class="post-metadata">

**Author:** ![faec](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/faec/32/46988_2.png) [@faec](https://discuss.elastic.co/u/faec)\
**Post date:** [August 22, 2019, 7:25pm UTC](https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031/2 "2019-08-22T19:25:34Z")

</div>

Welcome! The syslog timestamp handling is rather confusing, as it can be affected by several settings. Can you share an accompanying `filebeat.yml` that exhibits the problem?

---

<div class="post-metadata">

**Author:** ![Kent\_Wang](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kent_wang/32/52610_2.png) [@Kent\_Wang](https://discuss.elastic.co/u/Kent_Wang)\
**Post date:** [August 23, 2019, 12:13am UTC](https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031/3 "2019-08-23T00:13:15Z")

</div>

Hi, it's been confirmed as a bug.

[https://github.com/elastic/beats/pull/13308](https://github.com/elastic/beats/pull/13308)

---

<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 20, 2019, 2:13am UTC](https://discuss.elastic.co/t/filebeat-7-3-syslog-auth-log-timezone-parsing-error/196031/4 "2019-09-20T02:13:17Z")

</div>

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