# Search error

**URL:** <https://discuss.elastic.co/t/search-error/50465>\
**Category:** Elasticsearch\
**Created:** [May 19, 2016, 3:53pm UTC](https://discuss.elastic.co/t/search-error/50465 "2016-05-19T15:53:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![clement](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/clement/32/6895_2.png) [@clement](https://discuss.elastic.co/u/clement)\
**Post date:** [May 19, 2016, 3:53pm UTC](https://discuss.elastic.co/t/search-error/50465/1 "2016-05-19T15:53:27Z")

</div>

Hi

i meet a problem when i try to make a search

this request work

curl -XGET [http://elasticsearch:9200/logstash-wsnotification\_application-2016.05.19/\_search?pretty](http://elasticsearch:9200/logstash-wsnotification_application-2016.05.19/_search?pretty) --data-binary '{  
"query" : { "match\_all" : {} },  
"size" : 1,  
"\_source" : []  
}'

resultat

{  
"took" : 24,  
"timed\_out" : false,  
"\_shards" : {  
"total" : 5,  
"successful" : 5,  
"failed" : 0  
},  
"hits" : {  
"total" : 2344977,  
"max\_score" : 1.0,  
"hits" : [ {  
"\_index" : "logstash-wsnotification\_application-2016.05.19",  
"\_type" : "wsnotification\_application",  
"\_id" : "AVTHRg5BEIZomS5yHk60",  
"\_score" : 1.0,  
"\_source" : {  
"message" : "2016-05-19 06:28:47,235 [27] INFO - RegisterDevice(string appId, string udid, string token, int languageId, string partnerCode) - TimeTaken 00:00:00.0095643",  
"@version" : "1",  
"@timestamp" : "2016-05-19T04:28:47.235Z",  
"beat" : {  
"hostname" : "EUISAFR597",  
"name" : "EUISAFR597"  
},  
"count" : 1,  
"fields" : null,  
"input\_type" : "log",  
"offset" : 45412754,  
"source" : "D:\LogApplicatives\WSNotifications\WSNotifications.log",  
"type" : "wsnotification\_application",  
"host" : "EUISAFR597",  
"tags" : ["beats\_input\_codec\_plain\_applied"],  
"Timestamp" : "2016-05-19 06:28:47,235",  
"info1" : "[27]",  
"Loglevel" : "INFO",  
"Action" : "RegisterDevice(string appId, string udid, string token, int languageId, string partnerCode) - TimeTaken 00:00:00.0095643",  
"TimeTaken" : 95643  
}  
} ]  
}  
}

and this fail

curl -XGET [http://elasticsearch:9200/logstash-wsnotification\_application-2016.05.19/\_search?pretty](http://elasticsearch:9200/logstash-wsnotification_application-2016.05.19/_search?pretty) --data-binary '{  
"query" : { "match\_all" : {} },  
"size" : 1,  
"\_source" : ["host"]  
}'

{  
"error" : {  
"root\_cause" : [ {  
"type" : "json\_parse\_exception",  
"reason" : "Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@417cc95a; line: 4, column: 20]"  
}, {  
"type" : "json\_parse\_exception",  
"reason" : "json\_parse\_exception: Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@58424628; line: 4, column: 20]"  
}, {  
"type" : "json\_parse\_exception",  
"reason" : "json\_parse\_exception: Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@76ccb30; line: 4, column: 20]"  
} ],  
"type" : "search\_phase\_execution\_exception",  
"reason" : "all shards failed",  
"phase" : "query",  
"grouped" : true,  
"failed\_shards" : [ {  
"shard" : 0,  
"index" : "logstash-wsnotification\_application-2016.05.19",  
"node" : "TDasJe89S-eLzmA8s5HI4A",  
"reason" : {  
"type" : "json\_parse\_exception",  
"reason" : "Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@417cc95a; line: 4, column: 20]"  
}  
}, {  
"shard" : 1,  
"index" : "logstash-wsnotification\_application-2016.05.19",  
"node" : "EyeXIc4PTgOTNt8QS7AcMA",  
"reason" : {  
"type" : "json\_parse\_exception",  
"reason" : "json\_parse\_exception: Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@58424628; line: 4, column: 20]"  
}  
}, {  
"shard" : 3,  
"index" : "logstash-wsnotification\_application-2016.05.19",  
"node" : "EyeXIc4PTgOTNt8QS7AcMA",  
"reason" : {  
"type" : "json\_parse\_exception",  
"reason" : "json\_parse\_exception: Unrecognized token 'host': was expecting ('true', 'false' or 'null')\n at [Source: [B@76ccb30; line: 4, column: 20]"  
}  
} ]  
},  
"status" : 500  
}

Is sombody see the error ?

---

<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 5, 2017, 10:50pm UTC](https://discuss.elastic.co/t/search-error/50465/2 "2017-07-05T22:50:22Z")

</div>


