How to create watcher email alert on a specific machine in lan?

alerting

(Aftab Ali) #1

Dear Team,

I am happy to use watcher feature in kibana but I want to create an alert on a specific machine in my local network, I am able to get threshold email via SMTP gmail.com but I am not able to see a report of which machine had high utilization like CPU usage and memory usage, Please guide me how to do that.

Best Regards
Aftab Ali
E-mail - aftab70@ymail.com


(rich collier) #2

There are some Watch examples in our "examples" GitHub repo. For example:


(Aftab Ali) #3

Dear Richcollier,

Thanks for the reply, I want to select host name when creating a watcher alert, I do not want to apply watcher in all machine in the network, please guide me, i am new with elk.


(rich collier) #4

Ah, understood. In that case, in the body of the search clause of Watcher's input section, just use the filter capability of elasticsearch's query DSL to select anything that you want. For example, to only consider data from a machine_name=webserver1:

...
                    "query": {
                      "bool": {
                        "filter": [
                          { "range": { "timestamp": {"gte": "now-10m"}}},
                          { "term":  { "machine_name": "webserver1"}}
                        ]
                      }
                    }
...

(system) #5

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