# Wrong timestamp in Alert index

**URL:** <https://discuss.elastic.co/t/wrong-timestamp-in-alert-index/318247>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-alerting\
**Created:** [November 6, 2022, 5:51am UTC](https://discuss.elastic.co/t/wrong-timestamp-in-alert-index/318247 "2022-11-06T05:51:18Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aniket\_Pant](https://avatars.discourse-cdn.com/v4/letter/a/77aa72/32.png) [@Aniket\_Pant](https://discuss.elastic.co/u/Aniket_Pant)\
**Post date:** [November 6, 2022, 5:51am UTC](https://discuss.elastic.co/t/wrong-timestamp-in-alert-index/318247/1 "2022-11-06T05:51:18Z")

</div>

Hi All,

I have created an alert which will do send alert on a specified index. I have chosen elasticsearch query index.

I have used metricbeat-\* index for monitoring system uptime if node goes down i will get the alert

Here is my query

```auto
{
"query": {
    "bool": {
      "filter": [
        {
          "bool": {
            "must": [
            {
             "term": {
             "metricset.name": "uptime"
            }
            },
            {
              "range":
              {
                "@timestamp": {
              "gte": "now-15m"
            }
              }
            }
            ]
          }
        }
      ]
    }
  }
}

```

Alert ScreenShot  
pic 1:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/1/d/1d445dda74a07dad21ea35f0d68a6bd4a01b8e86.png)

pic2:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/7/3/73ed14b8a7bd8768168fcb630ec1be79a0341a11.png)

pic3:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/f/5/f516bfa3abd872bcdf68f05f88280791a810b27c.png)

Alert output will send to below index

```auto
PUT test
{
  "settings": {
    "number_of_shards": 1,
    "number_of_replicas": 0
  },
  "mappings": {
    "properties": {
      "timestamp":{"type": "date"},
      "rule_id":{"type": "text"},
      "rule_name":{"type": "text"},
      "alert_id":{"type": "text"},
      "context_message":{"type": "text"}
    }
  }
}

```

Result i am getting , **the system was down today at morning 10.43 but it is showing evening 5.**

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/5/1/51e56887e386deb8c2349bad111e5556ead3b0f7.png)

How can i correct this ?

---

<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:** [December 4, 2022, 5:51am UTC](https://discuss.elastic.co/t/wrong-timestamp-in-alert-index/318247/2 "2022-12-04T05:51:23Z")

</div>

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