# Alerts mail to us if curator job doesn't work fine?

**URL:** https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900
**Category:** Elasticsearch
**Created:** [April 19, 2017, 1:57pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900 "2017-04-19T13:57:52Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)
#### Post date: [April 19, 2017, 1:57pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/1 "2017-04-19T13:57:52Z")

</div>

HI,

I Created periodic backups using curator and sends the status report to logs.txt file . But my question is:

1. SO, every day i have to see the logs.txt file or azure storage account to check whether periodic backups were created or not. Suppose the curator job has failed then how can i able to know without seeing logs.txt and azure storage account . Is there any alerting mail system in ES to the admin saying that the snapshot job is failed .

Is this possible in Elasticsearch?

Thanks

---

<div class="post-metadata">

### Author: ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)
#### Post date: [April 19, 2017, 4:40pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/2 "2017-04-19T16:40:26Z")

</div>

There are a few ways to do this. One of the big ones is that the Curator log can be in json format:

```auto
logging:
  loglevel: INFO
  logfile: /path/to/curator.log
  logformat: json

```

With this, the curator logs can be sent to Logstash, or Elasticsearch (including via an ingest pipeline). Once the events are there, you can create Alerts (if using x-pack) for job completion. If you're not using x-pack, you could write your own parser and/or search to look for that, and alert yourself.

---

<div class="post-metadata">

### Author: ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)
#### Post date: [April 19, 2017, 4:57pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/3 "2017-04-19T16:57:09Z")

</div>

Thanks @theuntergeek

> [@theuntergeek](#):
>
> you could write your own parser and/or search to look for that, and alert yourself

I want to send data to ES or logstash and write a code in such a way it will catch "job completed" string from the curator logs json.  
For alerting myself also i have to search in ES right then how can i say it is alerting me because i am going and searching in the ES or is there any other way?

Correct me if i am wrong.

> [@theuntergeek](#):
>
> There are a few ways to do this

Can you please say what are other easy ways to do this?

THANKS

---

<div class="post-metadata">

### Author: ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)
#### Post date: [April 19, 2017, 5:46pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/4 "2017-04-19T17:46:15Z")

</div>

> [@Yaswanth](#):
>
> For alerting myself also i have to search in ES right then how can i say it is alerting me because i am going and searching in the ES or is there any other way?

Watcher/Alerting would do it.

> [@Yaswanth](#):
>
> Can you please say what are other easy ways to do this?

These would be more manually scripted ways of just tailing the log file and looking for the expected strings, and sending you an email. Potentially, you could use Logstash to read these in, and use the email output plugin to send a notification.

---

<div class="post-metadata">

### Author: ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)
#### Post date: [April 24, 2017, 7:33am UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/5 "2017-04-24T07:33:03Z")

</div>

Thanks @theuntergeek

> [@theuntergeek](#):
>
> logging:  
> loglevel: INFO  
> logfile: /path/to/curator.log  
> logformat: json

i had implemented these .

Now i want to send the `curator.log` file through ingest pipeline to Elasticsearch `Curator Logs` index , i went though the ingest pipline [documentation](https://www.elastic.co/blog/new-way-to-ingest-part-1) in that i didn't find some steps like

Usually in logstash we will use the below config to send data to ES .

```
input {
  file {
    path => "C:\Users\thunder\Desktop\curator.log"
    codec => json
    start_position => "beginning"
   
  }
}
output {
elasticsearch {
    hosts => "http://localhost:9200/"
    index => "data"
}
stdout{
codec => rubydebug
}
}

```

1)Like the same way as above how can i send the logs to ES using ingest pipeline?  
2) Do i have to do this method manually everytime to send data to ES but i want my curator logs to be sent to ES automatically when curator generate logs ? Does this can be done without logstash ?  
3) Is this possible in Elasticsearch 2.4.1?

FYI - I am not using Filebeat

Any help is highly appreciated

---

<div class="post-metadata">

### Author: ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)
#### Post date: [April 24, 2017, 3:49pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/6 "2017-04-24T15:49:40Z")

</div>

There is currently no way to send Curator logs to Elasticsearch _to an ingest pipeline_ of which I am aware, other than Beats. You would have to code your own, or you can send with Logstash, as you have configured above.

---

<div class="post-metadata">

### Author: ![Yaswanth](https://avatars.discourse-cdn.com/v4/letter/y/94ad74/32.png) [@Yaswanth](https://discuss.elastic.co/u/Yaswanth)
#### Post date: [April 24, 2017, 4:40pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/7 "2017-04-24T16:40:35Z")

</div>

Thanks

> [@theuntergeek](#):
>
> There is currently no way to send Curator logs to Elasticsearch to an ingest pipeline of which I am aware, other than Beats

Okay then i will install Filebeat and try it . Once configured the the curator log data will go directly to ES index right not need to send manually every time?

> [@theuntergeek](#):
>
> you can send with Logstash, as you have configured above.

Do i have to do above method manually everytime to send data to ES but i want my curator logs to be sent to ES automatically when curator generate logs. Is it possible using logstash ?

Thanks

---

<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: [May 22, 2017, 4:41pm UTC](https://discuss.elastic.co/t/alerts-mail-to-us-if-curator-job-doesnt-work-fine/82900/8 "2017-05-22T16:41:44Z")

</div>

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