# Elasticsearch Search Down - Server running

**URL:** <https://discuss.elastic.co/t/elasticsearch-search-down-server-running/17740>\
**Category:** Elasticsearch\
**Created:** [May 27, 2014, 6:16am UTC](https://discuss.elastic.co/t/elasticsearch-search-down-server-running/17740 "2014-05-27T06:16:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pratik\_Poddar](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/pratik_poddar/32/1529_2.png) [@Pratik\_Poddar](https://discuss.elastic.co/u/Pratik_Poddar)\
**Post date:** [May 27, 2014, 6:16am UTC](https://discuss.elastic.co/t/elasticsearch-search-down-server-running/17740/1 "2014-05-27T06:16:29Z")

</div>

My server was running fine until I start getting this error for search  
queries:

RequestError: TransportError(400, u'SearchPhaseExecutionException[Failed to  
execute phase [query], all shards failed; shardFailures

{[bgh1FwvvTmydjtDhY-reCA][article-index][3]:  
SearchParseException[[article-index][3]: from[-1],size[-1]: Parse Failure  
[Failed to parse source [{"query": {"custom\_score": {"query":  
{"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
"domain"]}}, "script": "\_score \*  
(1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
QueryParsingException[[article-index] [custom\_score] the script could not  
be loaded]; nested: ScriptException[dynamic scripting disabled]; }

{[bgh1FwvvTmydjtDhY-reCA][article-index][4]:  
SearchParseException[[article-index][4]: from[-1],size[-1]: Parse Failure  
[Failed to parse source [{"query": {"custom\_score": {"query":  
{"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
"domain"]}}, "script": "\_score \*  
(1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
QueryParsingException[[article-index] [custom\_score] the script could not  
be loaded]; nested: ScriptException[dynamic scripting disabled]; }

{[bgh1FwvvTmydjtDhY-reCA][article-index][1]:  
SearchParseException[[article-index][1]: from[-1],size[-1]: Parse Failure  
[Failed to parse source [{"query": {"custom\_score": {"query":  
{"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
"domain"]}}, "script": "\_score \*  
(1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
QueryParsingException[[article-index] [custom\_score] the script could not  
be loaded]; nested: ScriptException[dynamic scripting disabled]; }

{[bgh1FwvvTmydjtDhY-reCA][article-index][2]:  
SearchParseException[[article-index][2]: from[-1],size[-1]: Parse Failure  
[Failed to parse source [{"query": {"custom\_score": {"query":  
{"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
"domain"]}}, "script": "\_score \*  
(1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
QueryParsingException[[article-index] [custom\_score] the script could not  
be loaded]; nested: ScriptException[dynamic scripting disabled]; }]' )

I do not understand what has been changed. Using pyelasticsearch, this is  
the query being pushed

```
bodyquery = {

    "custom_score": {
        "script" : "_score * ("+str(1.0+recency)+"**(doc['articleid'].value*50000.0/"+maxarticleid+"))",
        "query": {
                "query_string": {"query": keywordstr, "fields": ["text", "title^3", "domain"]}
        }
    }
}

```

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [May 27, 2014, 4:33pm UTC](https://discuss.elastic.co/t/elasticsearch-search-down-server-running/17740/2 "2014-05-27T16:33:00Z")

</div>

Did you upgrade to 1.2? Dynamic scripts are now disabled by default.

> <https://github.com/elastic/elasticsearch/pull/5943>
>
> Also modifies the documentation for this, adding an example of using a preloaded… script.
> 
> Closes #5853

--  
Ivan

On Mon, May 26, 2014 at 11:16 PM, Pratik Poddar [pratik.phodu@gmail.com](mailto:pratik.phodu@gmail.com)wrote:

> My server was running fine until I start getting this error for search  
> queries:
> 
> RequestError: TransportError(400, u'SearchPhaseExecutionException[Failed  
> to execute phase [query], all shards failed; shardFailures
> 
> {[bgh1FwvvTmydjtDhY-reCA][article-index][3]:  
> SearchParseException[[article-index][3]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"query": {"custom\_score": {"query":  
> {"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
> "domain"]}}, "script": "\_score \*  
> (1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
> QueryParsingException[[article-index] [custom\_score] the script could not  
> be loaded]; nested: ScriptException[dynamic scripting disabled]; }
> 
> {[bgh1FwvvTmydjtDhY-reCA][article-index][4]:  
> SearchParseException[[article-index][4]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"query": {"custom\_score": {"query":  
> {"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
> "domain"]}}, "script": "\_score \*  
> (1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
> QueryParsingException[[article-index] [custom\_score] the script could not  
> be loaded]; nested: ScriptException[dynamic scripting disabled]; }
> 
> {[bgh1FwvvTmydjtDhY-reCA][article-index][1]:  
> SearchParseException[[article-index][1]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"query": {"custom\_score": {"query":  
> {"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
> "domain"]}}, "script": "\_score \*  
> (1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
> QueryParsingException[[article-index] [custom\_score] the script could not  
> be loaded]; nested: ScriptException[dynamic scripting disabled]; }
> 
> {[bgh1FwvvTmydjtDhY-reCA][article-index][2]:  
> SearchParseException[[article-index][2]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"query": {"custom\_score": {"query":  
> {"query\_string": {"query": "Arvi", "fields": ["text", "title^3",  
> "domain"]}}, "script": "\_score \*  
> (1.000008\*\*(doc['articleid'].value\*50000.0/100000.0))"}}}]]]; nested:  
> QueryParsingException[[article-index] [custom\_score] the script could not  
> be loaded]; nested: ScriptException[dynamic scripting disabled]; }]' )
> 
> I do not understand what has been changed. Using pyelasticsearch, this is  
> the query being pushed
> 
> ```
> bodyquery = {
> 
> "custom_score": {
> "script" : "_score * ("+str(1.0+recency)+"**(doc['articleid'].value*50000.0/"+maxarticleid+"))",
> "query": {
> "query_string": {"query": keywordstr, "fields": ["text", "title^3", "domain"]}
> }
> }
> }
> 
> ```
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/66b3ba4f-e062-42b2-a144-956fff13a5b0%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQArnEpL%2Bp6P8E3yx2VZENF%2BQXrXjHJ-fRvvJXA9ndtEeQ%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQArnEpL%2Bp6P8E3yx2VZENF%2BQXrXjHJ-fRvvJXA9ndtEeQ%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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:** [July 6, 2017, 1:26am UTC](https://discuss.elastic.co/t/elasticsearch-search-down-server-running/17740/3 "2017-07-06T01:26:37Z")

</div>


