# ElasticSearch cluster coming down when running certain types of wildcard searches

**URL:** https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695
**Category:** Elasticsearch
**Created:** [February 2, 2017, 2:33pm UTC](https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695 "2017-02-02T14:33:55Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![rboorugu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rboorugu/32/34358_2.png) [@rboorugu](https://discuss.elastic.co/u/rboorugu)
#### Post date: [February 2, 2017, 2:33pm UTC](https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695/1 "2017-02-02T14:33:56Z")

</div>

We are on ES5 and having some issues figuring the problem is - some type of search queries are completely bringing down elastic search, downtime can range from 5-15 minutes. cluster sometimes stays healthy green and in some times it can very soon turn to Red.

Below are some types are queries which are bringing it down (we convert the search phrases into boolean queries)

1. 31-2-3\*  
below is the boolean query for above which is used to run against ES - anything you see is incorrect?  
{  
"span\_near": {  
"clauses": [  
{  
"span\_term": {  
"Content": "31"  
}  
},  
{  
"span\_term": {  
"Content": "2"  
}  
},  
{  
"span\_multi": {  
"match": {  
"wildcard": {  
"Content": "3\*"  
}  
}  
}  
}  
],  
"slop": 0,  
"in\_order": true  
}  
}

2. com\* w/5 1205 w/15 reasonable

{  
"span\_near": {  
"clauses": [  
{  
"span\_near": {  
"clauses": [  
{  
"span\_multi": {  
"match": {  
"prefix": {  
"Content": "com"  
}  
}  
}  
},  
{  
"span\_term": {  
"Content": "1205"  
}  
}  
],  
"slop": "5",  
"in\_order": false  
}  
},  
{  
"span\_term": {  
"Content": "reasonable"  
}  
}  
],  
"slop": "15",  
"in\_order": false  
}  
}

Let us know if you guys find anything incorrect in query generation.

Appreciate your help on this.

---

<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: [February 5, 2017, 9:44am UTC](https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695/2 "2017-02-05T09:44:08Z")

</div>

> [@rboorugu](#):
>
> "slop": "15",

That's pretty huge, why so large?

---

<div class="post-metadata">

### Author: ![rboorugu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rboorugu/32/34358_2.png) [@rboorugu](https://discuss.elastic.co/u/rboorugu)
#### Post date: [February 6, 2017, 3:49pm UTC](https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695/3 "2017-02-06T15:49:21Z")

</div>

> [@rboorugu](#):
>
> com\* w/5 1205 w/15 reasonable

dont get it search query is below  
com\* w/5 1205 w/15 reasonable

above is a proximity search in which 1205 has to be with 15 words of reasonable for which slop of 15 has to be added isn't that right?

---

<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: [March 6, 2017, 3:49pm UTC](https://discuss.elastic.co/t/elasticsearch-cluster-coming-down-when-running-certain-types-of-wildcard-searches/73695/4 "2017-03-06T15:49:36Z")

</div>

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