# Elastic/elasticsearch-ruby

**URL:** https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130
**Category:** Elasticsearch
**Created:** [January 21, 2019, 10:19pm UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130 "2019-01-21T22:19:55Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Karthik\_K\_G](https://avatars.discourse-cdn.com/v4/letter/k/fbc32d/32.png) [@Karthik\_K\_G](https://discuss.elastic.co/u/Karthik_K_G)
#### Post date: [January 21, 2019, 10:19pm UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/1 "2019-01-21T22:19:55Z")

</div>

Hi Team,  
After going through the below repo

> **[elastic/elasticsearch-ruby](https://github.com/elastic/elasticsearch-ruby)**
>
> Ruby integrations for Elasticsearch. Contribute to elastic/elasticsearch-ruby development by creating an account on GitHub.

I haven't seen anything related to down node information in any of the API like client.cluster.health or client.cluster.state or client.cluster.stats etc  
For example I have 6 data nodes and 3 master nodes, if one of my one data node goes down, how do I identify that that particular node went down. Is there a way around here.

Your answer here is highly appreciated

Thanks & regards,  
Karthik

---

<div class="post-metadata">

### Author: ![karmi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/karmi/32/44951_2.png) [@karmi](https://discuss.elastic.co/u/karmi)
#### Post date: [January 25, 2019, 5:47pm UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/2 "2019-01-25T17:47:01Z")

</div>

Hello, once the node is down, ie. not accessible, it is removed from the cluster state, and therefore isn't included in any API output. You should, of course, see the requests to a node like that fail in the logs, ie. when you enable the logging for the Ruby client.

> (...) how do I identify that that particular node went down.

The question is why would you like to do that? The Ruby client has the "Reloading Nodes" feature ([https://github.com/elastic/elasticsearch-ruby/tree/master/elasticsearch-transport#reloading-hosts](https://github.com/elastic/elasticsearch-ruby/tree/master/elasticsearch-transport#reloading-hosts)), where you can reload the list of nodes from the cluster state dynamically.

---

<div class="post-metadata">

### Author: ![Karthik\_K\_G](https://avatars.discourse-cdn.com/v4/letter/k/fbc32d/32.png) [@Karthik\_K\_G](https://discuss.elastic.co/u/Karthik_K_G)
#### Post date: [January 26, 2019, 9:02pm UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/3 "2019-01-26T21:02:09Z")

</div>

Hi Karel, Thanks for your answer here. However, I am trying to get the node which went down so that I can setup an alert when the node goes down. In that way I know exactly which node went down and I work on that node itself.

---

<div class="post-metadata">

### Author: ![karmi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/karmi/32/44951_2.png) [@karmi](https://discuss.elastic.co/u/karmi)
#### Post date: [January 27, 2019, 5:48am UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/4 "2019-01-27T05:48:30Z")

</div>

Understood! This sounds like a job for Elasticsearch monitoring, rather than the client — have a look at [https://www.elastic.co/products/stack/monitoring](https://www.elastic.co/products/stack/monitoring), which is included in the default distribution.

---

<div class="post-metadata">

### Author: ![Karthik\_K\_G](https://avatars.discourse-cdn.com/v4/letter/k/fbc32d/32.png) [@Karthik\_K\_G](https://discuss.elastic.co/u/Karthik_K_G)
#### Post date: [January 28, 2019, 12:51am UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/5 "2019-01-28T00:51:42Z")

</div>

Ok. That looks pretty good monitoring. Just one question here. Thanks for your help.

---

<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, 2019, 12:51am UTC](https://discuss.elastic.co/t/elastic-elasticsearch-ruby/165130/6 "2019-02-25T00:51:47Z")

</div>

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