# Search is not working properly on cluster 2 node setup

**URL:** <https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851>\
**Category:** Elasticsearch\
**Created:** [January 10, 2023, 7:44pm UTC](https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851 "2023-01-10T19:44:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![arjunmalu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arjunmalu/32/100548_2.png) [@arjunmalu](https://discuss.elastic.co/u/arjunmalu)\
**Post date:** [January 10, 2023, 7:44pm UTC](https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851/1 "2023-01-10T19:44:01Z")

</div>

Hi Elastic team,

I am using Elasticsearch service on 2 node setup. Both the nodes have default configuration (elasticsearch.yml).

Case : Suppose there are 50 entries in a list to search from. A new entry ("newentry51") is added in the list making the total count of entries = 51. After restarting both the nodes, if I try to search "newentry51", then "newentry51" will come in results only on every alternate occasion i.e. (1st time search - getting "newentry51" in results, 2nd time search - not getting, 3rd time search - getting, and so on...).

Please suggest if there is any configuration to automatically refresh search index after rebooting the nodes or if there is any approach to solve this problem.

------------------------elasticsearch.yml------------------------------

```auto
cluster.name: log-collector
path.data: /var/cache/secmgt-elastic-data/log-collector
path.logs: /var/log/elasticsearch
node.master: true
node.data: true
#bootstrap.memory_lock: true # this one added new
discovery.zen.hosts_provider: file
#discovery.zen.ping.unicast.hosts: [“192.xxx.xxx.x:xxx1”, "192.xxx.xxx.x:xxx2”]
# set the master node IP if the master is remote

# Configuration to check out of memory error
indices.fielddata.cache.size: 40%
indices.breaker.fielddata.limit: 60%
indices.breaker.request.limit: 40%
indices.breaker.total.limit: 70%
# Configuration to enable performance Writes
#index.translog.flush_threshold_size: 1gb //need to set
#index.refresh_interval: 10s //need to set
# set the following only on SSD, default is good for spin disk
#indices.store.throttle.max_bytes_per_sec: 100mb
bootstrap.system_call_filter: false
network.host: x.x.x.x
network.publish_host: _eth0_

```

* * *

Setup Details : cluster 2-node setup

\*This problem is happening after VM reboot

Thanks.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [January 10, 2023, 10:00pm UTC](https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851/2 "2023-01-10T22:00:54Z")

</div>

Welcome to our community! 😃

Please share an example that we can use to replicate this, eg documents and mappings, your search request etc.

---

<div class="post-metadata">

**Author:** ![arjunmalu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arjunmalu/32/100548_2.png) [@arjunmalu](https://discuss.elastic.co/u/arjunmalu)\
**Post date:** [January 11, 2023, 5:39am UTC](https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851/3 "2023-01-11T05:39:36Z")

</div>

Please check the description, I have shared configurations and some extra details in the end. Also there is an example in the description given to follow.

---

<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 8, 2023, 5:40am UTC](https://discuss.elastic.co/t/search-is-not-working-properly-on-cluster-2-node-setup/322851/4 "2023-02-08T05:40:04Z")

</div>

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