# Temporarily prevent Elastic from accepting requests

**URL:** <https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521>\
**Category:** Elasticsearch\
**Created:** [April 10, 2020, 2:42pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521 "2020-04-10T14:42:16Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jasonperrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jasonperrone/32/128615_2.png) [@jasonperrone](https://discuss.elastic.co/u/jasonperrone)\
**Post date:** [April 10, 2020, 2:42pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/1 "2020-04-10T14:42:16Z")

</div>

I am practicing doing an upgrade of Elastic 7.0.0 -\> 7.6.2 in a UAT instance. Here's what keeps happening. On the old instance I create a snapshot. I shut it down. I turn on the new instance. I try to restore the snapshot I just made. BOOM! because some sneaky user has already managed to create a new index in the new instance with the same name as an index in my snapshot.

How would you recommend I prevent this? I just had an idea... what if that first time I start the new instance I start it on a different port other then 9200? Then the client wouldn't be able to hit it. Problem with that is the client would end up getting an error, or I will miss indexing what the client was trying to index, like a log event with Winston. Is there a cleaner way for me to have my new instance start up by temporarily blocking requests until my snapshot is restored?

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [April 13, 2020, 7:58am UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/2 "2020-04-13T07:58:05Z")

</div>

How many nodes do you have in your cluster? Can you perform a rolling upgrade? If not you might be able to temporarily block access through IP tables, but that will mean users will see connection errors.

---

<div class="post-metadata">

**Author:** ![jasonperrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jasonperrone/32/128615_2.png) [@jasonperrone](https://discuss.elastic.co/u/jasonperrone)\
**Post date:** [April 13, 2020, 12:04pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/3 "2020-04-13T12:04:18Z")

</div>

It's the only node in the cluster, Christian... a lonely cluster of one...

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [April 13, 2020, 2:15pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/4 "2020-04-13T14:15:11Z")

</div>

Then there are few options and FBlientscwill notice. IP tables is probably the best way.

---

<div class="post-metadata">

**Author:** ![jasonperrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jasonperrone/32/128615_2.png) [@jasonperrone](https://discuss.elastic.co/u/jasonperrone)\
**Post date:** [April 13, 2020, 2:40pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/5 "2020-04-13T14:40:36Z")

</div>

Understood, Christian. Thanks for all 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:** [May 11, 2020, 2:47pm UTC](https://discuss.elastic.co/t/temporarily-prevent-elastic-from-accepting-requests/227521/6 "2020-05-11T14:47:35Z")

</div>

Closed on May 11, 2020, 2:47pm UTC

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